Originally Posted by
wengi
Use swapon / swapoff:
Code:
[admin@blechbuechse root]$ swapoff /dev/discs/disc0/part1
[admin@blechbuechse root]$ free
total used free shared buffers cached
Mem: 13964 13448 516 0 1548 7336
-/+ buffers/cache: 4564 9400
Swap: 0 0 0
[admin@blechbuechse root]$ swapon /dev/discs/disc0/part1
[admin@blechbuechse root]$ free
total used free shared buffers cached
Mem: 13964 13696 268 0 1548 7336
-/+ buffers/cache: 4812 9152
Swap: 500432 0 500432
wengi
Hi,
I am back, as the problem persists.
My router No.1 worked fine , Olegs firmware,
applications installed on usb 4GB stick
and part2 /opt mounted regularly, part1 was on.
I reflashed it with Koppel for cellular modem support.
And part1 stopped to be swap-on, /opt directory is empty
I insert the same usb stick into my No.2 router
and part1 swap is on, /part2 /opt is mounted and I can run applications.
I can swapon on router No.1 and it works.
Unfortunately /opt directory is empty, so no preinstalled applications to run.
I discover the problem with putty when
ssh telnet session is closed immediately for router No.1
As I use the same system hdd stick on both routers,
what can be done to have
part1 swap-on and part2 /opt mounted on router No.1 on boot ?
As you can see, swap was off
so I followed your great tutorial
mkswap
swapon
Code:
[admin@aa /opt]$ free
total used free shared buffers
Mem: 30324 14264 16060 0 1772
Swap: 0 0 0
Total: 30324 14264 16060
[admin@aa /opt]$ mkswap /dev/discs/disc0/part1
Setting up swapspace version 1, size = 534499328 bytes
[admin@aa /opt]$ free
total used free shared buffers
Mem: 30324 14272 16052 0 1772
Swap: 0 0 0
Total: 30324 14272 16052
[admin@aa /opt]$ swapon /dev/discs/disc0/part1
[admin@aa /opt]$ free
total used free shared buffers
Mem: 30324 14532 15792 0 1772
Swap: 521968 0 521968
Total: 552292 14532 537760
[admin@aa /opt]$ free
total used free shared buffers
Mem: 30324 14532 15792 0 1772
Swap: 521968 0 521968
Total: 552292 14532 537760
[admin@aa /opt]$
Code:
[admin@aa root]$ ls
[admin@aa root]$ cd /
[admin@aa /]$ cd /opt
[admin@aa /opt]$ ls
[admin@aa /opt]$ mount
/dev/root on / type squashfs (ro)
none on /dev type devfs (rw)
proc on /proc type proc (rw)
ramfs on /tmp type ramfs (rw)
usbfs on /proc/bus/usb type usbfs (rw)
/dev/discs/disc0/part2 on /tmp/mnt/disc0_2 type ext3 (rw,noatime)
/dev/discs/disc0/part3 on /tmp/mnt/disc0_3 type ext3 (rw,noatime)
[admin@aa /opt]$ free
total used free shared buffers
Mem: 30324 14256 16068 0 1772
Swap: 0 0 0
Total: 30324 14256 16068
[admin@aa /opt]$ fdisk -l
Disk /dev/scsi/host0/bus0/target0/lun0/disc: 4009 MB, 4009754624 bytes
145 heads, 48 sectors/track, 1125 cylinders
Units = cylinders of 6960 * 512 = 3563520 bytes
Device Boot Start End Blocks Id System
/dev/scsi/host0/bus0/target0/lun0/part1 1 150 521976 82 Linux swap
/dev/scsi/host0/bus0/target0/lun0/part2 151 500 1218000 83 Linux
/dev/scsi/host0/bus0/target0/lun0/part3 501 1125 2175000 83 Linux
[admin@aa /opt]$ df -l
df: illegal option -- l
BusyBox v1.1.3 (2008.04.25-08:17+0000) multi-call binary
Usage: df [-hmk] [FILESYSTEM ...]
[admin@aa /opt]$ df -l
df: illegal option -- l
BusyBox v1.1.3 (2008.04.25-08:17+0000) multi-call binary
Usage: df [-hmk] [FILESYSTEM ...]
edited once again (was empty)
vi /etc/fstab
echo "/etc/fstab" >> /usr/local/.files
edited pre-mount
vi /usr/local/sbin/pre-mount
and on reboot
flashfs save && flashfs commit && flashfs enable && reboot
======
Code:
[admin@aa root]$ mount
/dev/root on / type squashfs (ro)
none on /dev type devfs (rw)
proc on /proc type proc (rw)
ramfs on /tmp type ramfs (rw)
usbfs on /proc/bus/usb type usbfs (rw)
/dev/discs/disc0/part2 on /opt type ext3 (rw,noatime)
/dev/discs/disc0/part3 on /tmp/mnt/disc0_3 type ext3 (rw,noatime)
[admin@aa root]$ free
total used free shared buffers cached
Mem: 30324 17492 12832 0 1864 8476
-/+ buffers/cache: 7152 23172
Swap: 521968 0 521968
[admin@aa root]$
So it works fine.
run mc
and clicking on arrow keys generates the following
AAAABBBBAAAAACCCCCDDDDAABBDDCCCDDABBBBBBBBACCDABD B
Ok. Closed putty session as there was no other way to press F10 for
mc exit
and get command line back
Opened new putty session
and arrows don't work in mc
so no way to use mc.
Any idea, any solution ?
Darius