File swaping on dd-wrt ???

Post new topic   Reply to topic    DD-WRT Forum Forum Index -> Broadcom SoC based Hardware
Goto page 1, 2  Next
Author Message
yzy-oui-fi
DD-WRT Guru


Joined: 03 Mar 2009
Posts: 2826
Location: France

PostPosted: Thu May 13, 2010 0:10    Post subject: File swaping on dd-wrt ??? Reply with quote
device used :whr-g54s
FW:DD-WRT v24 SP2 Nokaid (13064)

here we go:
I try to enable file swaping on cifs part as mentionned on the wiki:
http://www.dd-wrt.com/wiki/index.php/Linux_SWAP

The cifs is mounted on jffs folowing to the wiki:

http://www.dd-wrt.com/wiki/index.php/JFFS_File_System#Using_CIFS_.28Client_Samba.29:_Storing_.2Fjffs_content_remotely


the trouble is that swapon refuse to activate the file swap

here is what i received with the

Code:
root@DD-WRT:/dev# /opt/bin/busybox swapon /mnt/myswap.swp
swapon: /mnt/myswap.swp: Invalid argument


and so of course:

Code:
root@DD-WRT:/dev# free
              total         used         free       shared      buffers
  Mem:        13004         7732         5272            0          484
 Swap:            0            0            0
Total:        13004         7732         5272


So I would like to know if someone have already enable a file swap or if the file swap section wiki came from a summer night dream??? Wink

_________________
DD-WRT WDS MESH + DASHBOARD (fr), DD-WRT network setting tool (tools.yzy-oui-fi.com), Wifi Business and IT guy After hours, My Blog, Free DD-WRT VPN Community(www.wrt-pptp-ww.com), DD-WRT pré-réglés pour réseau outdoor(hotspot.yzy-oui-fi.com), Nouveau Forum DD-WRT francophone
Sponsor
Bruty
DD-WRT Novice


Joined: 21 Nov 2009
Posts: 7

PostPosted: Thu May 13, 2010 13:41    Post subject: Reply with quote
example:

dd if=/dev/zero of=/mnt/tmp/swap bs=1k count=32000

/mnt/swap/mkswap -c /mnt/tmp/swap

/mnt/swap/swapon /mnt/tmp/swap
yzy-oui-fi
DD-WRT Guru


Joined: 03 Mar 2009
Posts: 2826
Location: France

PostPosted: Thu May 13, 2010 14:51    Post subject: Reply with quote
doesn't work...Nice try Wink
_________________
DD-WRT WDS MESH + DASHBOARD (fr), DD-WRT network setting tool (tools.yzy-oui-fi.com), Wifi Business and IT guy After hours, My Blog, Free DD-WRT VPN Community(www.wrt-pptp-ww.com), DD-WRT pré-réglés pour réseau outdoor(hotspot.yzy-oui-fi.com), Nouveau Forum DD-WRT francophone
frater
DD-WRT Guru


Joined: 07 Jun 2006
Posts: 2777

PostPosted: Thu May 13, 2010 22:22    Post subject: Reply with quote
yzy-oui-fi wrote:
doesn't work...Nice try Wink

# free
total used free shared buffers cached
Mem: 124948 41604 83344 0 18168 11840
-/+ buffers/cache: 11596 113352
Swap: 241880 0 241880

# swapon -s
Filename Type Size Used Priority
/dev/sda1 partition 241880 0 -1


I'm using a swap partition (not a file)and it is automatically mounted using one of my optware scripts (/opt/etc/init.d/S10swap)

_________________
Asus RT16N + OTRW
Kingston 4GB USB-disk 128 MB swap + 1.4GB ext3 on /opt + 2 GB ext3 on /mnt
Copperjet 1616 modem in ZipB-config
Asterisk, pixelserv & Pound running on router
Another Asus RT16N as WDS-bridge

DD-WRT v24-sp2 vpn (c) 2010 NewMedia-NET GmbH
Release: 12/16/10 (SVN revision: 15758M)


Last edited by frater on Thu May 13, 2010 22:25; edited 2 times in total
crashfly
DD-WRT Guru


Joined: 24 Feb 2009
Posts: 2026
Location: Sol System > Earth > USA > Arkansas

PostPosted: Thu May 13, 2010 22:23    Post subject: Reply with quote
Swap file works on my router.

Using the command "swapon -s" gets the following:
Code:
Filename                        Type            Size    Used    Priority
/dev/scsi/host0/bus0/target0/lun0/part2 partition       249848  0       -1

_________________
E3000 22200M KongVPN K26
WRT600n v1.1 refirb mega 18767 BS K24 NEWD2 [not used]
WRT54G v2 16214 BS K24 [access point]

Try Dropbox for syncing files - get 2.5gb online for free by signing up.

Read! Peacock thread
*PLEASE* upgrade PAST v24SP1 or no support.
buddee
DD-WRT Guru


Joined: 06 Feb 2010
Posts: 7401
Location: Little Rock

PostPosted: Thu May 13, 2010 22:49    Post subject: Reply with quote
Read about that in another post

http://www.dd-wrt.com/phpBB2/viewtopic.php?t=70336&highlight=

You all may find interest in it as well....

_________________
Wireless N Config | Linking Routers | DD-WRT Wiki | DD-WRT Builds | Peacock - Broadcom FAQ

Having problems with port forwarding? Check out Port Forward Troubleshooting for more info.
crashfly
DD-WRT Guru


Joined: 24 Feb 2009
Posts: 2026
Location: Sol System > Earth > USA > Arkansas

PostPosted: Thu May 13, 2010 23:15    Post subject: Re: File swaping on dd-wrt ??? Reply with quote
yzy-oui-fi wrote:
the trouble is that swapon refuse to activate the file swap

here is what i received with the

Code:
root@DD-WRT:/dev# /opt/bin/busybox swapon /mnt/myswap.swp
swapon: /mnt/myswap.swp: Invalid argument

I just realized what "might" be your problem is with this above command. You must use the "direct" partition as the argument and it does not need to be mounted. From what I see though, you are using the file version of the program and that requires a special syntax I do believe. Here is the output of the usage:
Usage:
Code:

 swapon -a [-e] [-v] [-f]             enable all swaps from /etc/fstab
 swapon [-p priority] [-v] [-f] <special>  enable given swap
 swapon -s                            display swap usage summary
 swapon -h                            display help
 swapon -V                            display version

The <special> parameter:
 {-L label | LABEL=label}             LABEL of device to be used
 {-U uuid  | UUID=uuid}               UUID of device to be used
 <device>                             name of device to be used
 <file>                               name of file to be used

I do believe that you are trying to use the version from the second line.

_________________
E3000 22200M KongVPN K26
WRT600n v1.1 refirb mega 18767 BS K24 NEWD2 [not used]
WRT54G v2 16214 BS K24 [access point]

Try Dropbox for syncing files - get 2.5gb online for free by signing up.

Read! Peacock thread
*PLEASE* upgrade PAST v24SP1 or no support.
yzy-oui-fi
DD-WRT Guru


Joined: 03 Mar 2009
Posts: 2826
Location: France

PostPosted: Thu May 13, 2010 23:48    Post subject: Reply with quote
you are right crash, this was what i used first, then i try the other way mentionned in the wiki without succeed.

i would like to insist on this points:

-WHR-G54s do not have usb so i could not use swap partition but file swap with cifs.

-i first try with V24SP1 then SP2 13064 (because it is for production network....No beta allowed)

@Crash if you could put light on your mind....Wink

_________________
DD-WRT WDS MESH + DASHBOARD (fr), DD-WRT network setting tool (tools.yzy-oui-fi.com), Wifi Business and IT guy After hours, My Blog, Free DD-WRT VPN Community(www.wrt-pptp-ww.com), DD-WRT pré-réglés pour réseau outdoor(hotspot.yzy-oui-fi.com), Nouveau Forum DD-WRT francophone


Last edited by yzy-oui-fi on Mon May 17, 2010 18:47; edited 1 time in total
yzy-oui-fi
DD-WRT Guru


Joined: 03 Mar 2009
Posts: 2826
Location: France

PostPosted: Mon May 17, 2010 18:44    Post subject: Reply with quote
up....? any solutions?
_________________
DD-WRT WDS MESH + DASHBOARD (fr), DD-WRT network setting tool (tools.yzy-oui-fi.com), Wifi Business and IT guy After hours, My Blog, Free DD-WRT VPN Community(www.wrt-pptp-ww.com), DD-WRT pré-réglés pour réseau outdoor(hotspot.yzy-oui-fi.com), Nouveau Forum DD-WRT francophone
LOM
DD-WRT Guru


Joined: 28 Dec 2008
Posts: 7631

PostPosted: Mon May 17, 2010 19:00    Post subject: Reply with quote
yzy-oui-fi wrote:

-i first try with V24SP1 then SP2 13064 (because it is for production network....No beta allowed)


Not a solution to your problem, I'm only curious of how you have managed to choose the 2 worst builds ever for Broadcom based devices. For a production network.. Very Happy

_________________
Kernel panic: Aiee, killing interrupt handler!
yzy-oui-fi
DD-WRT Guru


Joined: 03 Mar 2009
Posts: 2826
Location: France

PostPosted: Mon May 17, 2010 19:55    Post subject: Reply with quote
LOM wrote:
yzy-oui-fi wrote:

-i first try with V24SP1 then SP2 13064 (because it is for production network....No beta allowed)


Not a solution to your problem, I'm only curious of how you have managed to choose the 2 worst builds ever for Broadcom based devices. For a production network.. Very Happy


Simply because when you make production network you do not have time to be gambler with beta release. So you manage with what dev's consider as stable release.

I play with beta at home but never for my customers network. It is very different to play on a network which own 10 clients and another which should be able to own 5 or 10 time more. There could be some very bothering issue with beta on prodution network, and i don't want to drive 500 km in a middle of a night for a network break down, spend two or three days on site without giving a solution just because it is a bug issue of a beta release...Am I clear enough? Wink

_________________
DD-WRT WDS MESH + DASHBOARD (fr), DD-WRT network setting tool (tools.yzy-oui-fi.com), Wifi Business and IT guy After hours, My Blog, Free DD-WRT VPN Community(www.wrt-pptp-ww.com), DD-WRT pré-réglés pour réseau outdoor(hotspot.yzy-oui-fi.com), Nouveau Forum DD-WRT francophone
oxygenx
DD-WRT Guru


Joined: 11 Nov 2007
Posts: 566

PostPosted: Mon May 17, 2010 21:04    Post subject: Reply with quote
you cannot swap directly on a network filesystem file because it's not a continous blockdevice. what the wiki ( http://www.dd-wrt.com/wiki/index.php/Linux_SWAP ) says with the loop device around the swap file is a work around this security measure.
got_milk
DD-WRT User


Joined: 05 Dec 2009
Posts: 377
Location: Toronto, Canada

PostPosted: Mon May 17, 2010 21:06    Post subject: Reply with quote
yzy-oui-fi wrote:
LOM wrote:
yzy-oui-fi wrote:

-i first try with V24SP1 then SP2 13064 (because it is for production network....No beta allowed)


Not a solution to your problem, I'm only curious of how you have managed to choose the 2 worst builds ever for Broadcom based devices. For a production network.. Very Happy


Simply because when you make production network you do not have time to be gambler with beta release. So you manage with what dev's consider as stable release.

I play with beta at home but never for my customers network. It is very different to play on a network which own 10 clients and another which should be able to own 5 or 10 time more. There could be some very bothering issue with beta on prodution network, and i don't want to drive 500 km in a middle of a night for a network break down, spend two or three days on site without giving a solution just because it is a bug issue of a beta release...Am I clear enough? Wink


I wouldn't use beta builds in production either but I would NEVER deploy SP1 or 13064 in any production environment, considering all the known problems 13064 has.

_________________
Peacock Thread | Wireless Drops/Slow? Got an Intel Card? Read this! | BrainSlayer Builds | Eko Builds

Netgear WNDR3700 - OpenWRT Kamikaze Bleeding Edge Trunk Builds
(retired) Linksys WRT310N v1 - DD-WRT v24-sp2 build 15693 std-nokaid-small NEWD2 K2.6
ReadtheAnnouncements!
DD-WRT Guru


Joined: 02 Mar 2010
Posts: 1362

PostPosted: Mon May 17, 2010 21:06    Post subject: Reply with quote
yzy-oui-fi wrote:
Simply because when you make production network you do not have time to be gambler with beta release.


So...put on a build that you should KNOW won't work? Shocked

You are right that it isn't a gamble...more of a sure thing that there will be major problems.

_________________
If I've said it once, I've must have said it a thousand times! READ the announcements at the start of the broadcom forum!
THESE:
http://www.dd-wrt.com/phpBB2/viewtopic.php?t=54889
http://www.dd-wrt.com/phpBB2/viewtopic.php?t=51486
http://www.dd-wrt.com/phpBB2/viewtopic.php?t=54845
http://www.dd-wrt.com/phpBB2/viewtopic.php?t=52043
(We'll wait....!) Wink
yzy-oui-fi
DD-WRT Guru


Joined: 03 Mar 2009
Posts: 2826
Location: France

PostPosted: Mon May 17, 2010 22:01    Post subject: Reply with quote
got_milk wrote:

I wouldn't use beta builds in production either but I would NEVER deploy SP1 or 13064 in any production environment, considering all the known problems 13064 has.


Ok so could you tell me which stable release you use for production network if you do not use SP1 or SP2(13064) which are the one recommanded to be more stable by dd-wrt website? V23sp2? ;)

ReadtheAnnouncements! wrote:

So...put on a build that you should KNOW won't work? Shocked

You are right that it isn't a gamble...more of a sure thing that there will be major problems.


the only real problem is the fact swap file could not be load.

Maybe this will seem incredible for lot of people here but i have wiman network covering 25km² support by dd-wrtv24sp1 rebuilt(to included my network setup as default parameters) running for 3 years without problems. So i think the bugs related to SP1 is not bothering in wds mesh network with chillispot running on gateway. the only thing bothering is that the gateway is wrt54GS 1.1 to enable the ssl captiv portal without overloading the memory.

So this is why i try to do something with cifs and file swaping.

_________________
DD-WRT WDS MESH + DASHBOARD (fr), DD-WRT network setting tool (tools.yzy-oui-fi.com), Wifi Business and IT guy After hours, My Blog, Free DD-WRT VPN Community(www.wrt-pptp-ww.com), DD-WRT pré-réglés pour réseau outdoor(hotspot.yzy-oui-fi.com), Nouveau Forum DD-WRT francophone


Last edited by yzy-oui-fi on Mon May 17, 2010 22:14; edited 1 time in total
Goto page 1, 2  Next Display posts from previous:    Page 1 of 2
Post new topic   Reply to topic    DD-WRT Forum Forum Index -> Broadcom SoC based Hardware All times are GMT

Navigation

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
You can attach files in this forum
You can download files in this forum