Please note the new address for this forum : forum.excito.org. The old address redirects here but I don't know for how long. Thanks !
New user's registration have been closed due to high spamming and low trafic on this forum. Please contact forum admins directly if you need an account. Thanks !
Swap partition gone
Swap partition gone
Hi,
I have somewhat of a problem; I started getting out of memory errors and quickly discovered that my total swap size was 0 kb. There doesn't seem to be a swap partition at all! It looks as if there is some problem with the disk. For example, when running cfdisk i get "FATAL ERROR: Cannot open disk drive - Press any key to exit cfdisk".
I don't have any idea what might have caused this. Can I recreate the swap partition somehow or do I have to perform a complete re-install? Can you help me out?
Thanks in advance!
juicer
I have somewhat of a problem; I started getting out of memory errors and quickly discovered that my total swap size was 0 kb. There doesn't seem to be a swap partition at all! It looks as if there is some problem with the disk. For example, when running cfdisk i get "FATAL ERROR: Cannot open disk drive - Press any key to exit cfdisk".
I don't have any idea what might have caused this. Can I recreate the swap partition somehow or do I have to perform a complete re-install? Can you help me out?
Thanks in advance!
juicer
Hi Juicer,
Could you give me the output of
and
/Tor
Could you give me the output of
Code: Select all
cat /proc/partitions
Code: Select all
ls -l /dev/hda*
Co-founder OpenProducts and Ex Excito Developer
Code: Select all
bubba:~# cat /proc/partitions
major minor #blocks name
3 0 312571224 hda
3 1 311532448 hda1
3 2 1036192 hda2
31 0 66 mtdblock0
31 1 1584 mtdblock1
31 2 462 mtdblock2
bubba:~# ls -l /dev/hda*
ls: /dev/hda*: No such file or directory
bubba:~#

That isn't really possible as the first command shows that you are using hda. And the fact you can actually log in to the machine shows that something is mounted...juicer wrote: This might have been a result of a upgrade gone wrong. I actually didn't notice it first. But I am at a loss on what to do about it...
What does
Code: Select all
mount
Code: Select all
bubba:~# mount
/dev/hda1 on / type ext3 (rw,noatime)
proc on /proc type proc (rw)
sysfs on /sys type sysfs (rw)
devpts on /dev/pts type devpts (rw,gid=5,mode=620)
tmpfs on /dev/shm type tmpfs (rw)
usbfs on /proc/bus/usb type usbfs (rw)
/var/samba/public on /home/storage type none (rw,bind)
/var/www/html on /home/web type none (rw,bind)
bubba:~#
right
So you do have /dev/hda1
This means there's basically two reasons why your "ls -l /dev/hda*" failed. Either your /dev/ is corrupted, or something went wrong with the command. Please check by going into dev (cd /dev) and enter "ls" to see what is there, and if it includes hda1 and hda2 ("ls | grep hda" may speed things up)
But all this is pretty academic, as it does nothing to solve. Here's a possible solution:
first verify the swap part is in your system:
it should return something like this:
ok, now check if the swap partition is active:
Another way to check is using the 'free' command:
Assuming nothing is returned, now manually turn on the swap using the swapon command
First RTFM:
then test by turning on swap:
It should then either crash or work
btw, all the above commands must of course be executed as root
So you do have /dev/hda1
This means there's basically two reasons why your "ls -l /dev/hda*" failed. Either your /dev/ is corrupted, or something went wrong with the command. Please check by going into dev (cd /dev) and enter "ls" to see what is there, and if it includes hda1 and hda2 ("ls | grep hda" may speed things up)
But all this is pretty academic, as it does nothing to solve. Here's a possible solution:
first verify the swap part is in your system:
Code: Select all
cat /etc/fstab | grep swap
Code: Select all
/dev/hda2 none swap sw 00
Code: Select all
[root@korona:/root]$ cat /proc/swaps
Filename Type Size Used Priority
/dev/hda2 partition 1036184 12712 -1
Code: Select all
[root@korona:/root]$ free
total used free shared buffers cached
Mem: 126940 118216 8724 0 2876 71600
-/+ buffers/cache: 43740 83200
Swap: 1036184 12712 1023472
First RTFM:
Code: Select all
man swapon
Code: Select all
swapon -a -v
btw, all the above commands must of course be executed as root
Thanks a lot for your help, Ubi! Here is the output from the commands you suggested:
Code: Select all
bubba:~# cat /etc/fstab | grep swap
/dev/hda2 none swap sw 0 0
bubba:~# cat /proc/swaps
bubba:~# free
total used free shared buffers cached
Mem: 62020 57368 4652 0 20976 15916
-/+ buffers/cache: 20476 41544
Swap: 0 0 0
bubba:~# swapon -a -v
swapon on /dev/hda2
swapon: cannot stat /dev/hda2: No such file or directory
bubba:~#
Well, that outcome shows your swap cannot be activated. This could even mean that your partition table is hosed, which is a very serious problem.
Now there's a few other tests that can be conducted. This includes running partition tools and low level disk checking. For me this is difficult to help out via a forum. Maybe I missed something and somebody else has a suggestion, but my suggestion would be, if the product in still within warranty, to contact the excito helpdesk. You may need to reinstall the bubba software (as the new OS is coming this is not even such a bad idea) or your HD needs replacing.
Ubi
Now there's a few other tests that can be conducted. This includes running partition tools and low level disk checking. For me this is difficult to help out via a forum. Maybe I missed something and somebody else has a suggestion, but my suggestion would be, if the product in still within warranty, to contact the excito helpdesk. You may need to reinstall the bubba software (as the new OS is coming this is not even such a bad idea) or your HD needs replacing.
Ubi
Hi,
Its very strange that /proc/partitions says that you have a hda2 (swap) partition. But the device node, /dev/hda2, is missing.
I assume that you have tried to restart your Bubba? It could be some problems with udev, the "device manager".
Could you give me the output of It should look something like
/Tor
Its very strange that /proc/partitions says that you have a hda2 (swap) partition. But the device node, /dev/hda2, is missing.
I assume that you have tried to restart your Bubba? It could be some problems with udev, the "device manager".
Could you give me the output of
Code: Select all
ps ax | grep udev
Code: Select all
1148 ? S<s 0:00 udevd --daemon
4145 pts/1 R+ 0:00 grep udev
Co-founder OpenProducts and Ex Excito Developer
Thanks Tor. This helped me out!
I didn't have udev up and running and it actually seemed that the udev package was missing completely (maybe from the previous failed upgrade). I re-installed it and got warnings that there was also a problem with the portmap package which was automatically resolved by apt-get. After a reboot, my swap is back in business and eveything seems to work. I still don't have the udevd process running, though...
and now, after a reboot:
I didn't have udev up and running and it actually seemed that the udev package was missing completely (maybe from the previous failed upgrade). I re-installed it and got warnings that there was also a problem with the portmap package which was automatically resolved by apt-get. After a reboot, my swap is back in business and eveything seems to work. I still don't have the udevd process running, though...
Code: Select all
bubba:~# ps ax | grep udev
1584 pts/0 S+ 0:00 grep udev
bubba:~# apt-get update
Hit http://update.excito.net bubba/main Packages
Hit http://update.excito.net bubba/main Release
Hit http://ftp.se.debian.org sarge/main Packages
Hit http://ftp.se.debian.org sarge/main Release
Reading Package Lists... Done
bubba:~# apt-get install udev
Reading Package Lists... Done
Building Dependency Tree... Done
The following extra packages will be installed:
portmap
The following NEW packages will be installed:
udev
The following packages will be upgraded:
portmap
1 upgraded, 1 newly installed, 0 to remove and 0 not upgraded.
1 not fully installed or removed.
Need to get 232kB/255kB of archives.
After unpacking 815kB of additional disk space will be used.
Do you want to continue? [Y/n] Y
Get:1 http://ftp.se.debian.org sarge/main udev 0.056-3 [232kB]
Fetched 232kB in 0s (573kB/s)
(Reading database ...
dpkg: serious warning: files list file for package `portmap' missing, assuming package has no files currently installed.
17962 files and directories currently installed.)
Preparing to replace portmap 5-9 (using .../archives/portmap_5-9_arm.deb) ...
Unpacking replacement portmap ...
Selecting previously deselected package udev.
Unpacking udev (from .../archives/udev_0.056-3_arm.deb) ...
Setting up portmap (5-9) ...
Starting portmap daemon: portmap.
Setting up udev (0.056-3) ...
Code: Select all
bubba:~# cat /proc/partitions
major minor #blocks name
3 0 312571224 hda
3 1 311532448 hda1
3 2 1036192 hda2
31 0 66 mtdblock0
31 1 1584 mtdblock1
31 2 462 mtdblock2
bubba:~# s -l /dev/hda*
-su: s: command not found
bubba:~# ls -l /dev/hda*
brw-rw---- 1 root disk 3, 0 1970-01-01 01:00 /dev/hda
brw-rw---- 1 root disk 3, 1 1970-01-01 01:00 /dev/hda1
brw-rw---- 1 root disk 3, 2 1970-01-01 01:00 /dev/hda2
bubba:~# cat /etc/fstab | grep swap
/dev/hda2 none swap sw 0 0
bubba:~# cat /proc/swaps
Filename Type Size Used Priority
/dev/hda2 partition 1036184 28168 -1
bubba:~# free
total used free shared buffers cached
Mem: 62020 59252 2768 0 488 44976
-/+ buffers/cache: 13788 48232
Swap: 1036184 28168 1008016
bubba:~# ps ax | grep udev
1599 pts/0 S+ 0:00 grep udev
Hi,
Juicer, my fault on the udev part. The ps command wont show anything on Bubba. It runs in another way than on Debian Etch where i looked.
The reason this failed seemed to be that udev, the application responsible for creating device nodes, such as /dev/hda2, for devices in the system (The replacement for devfs), somehow got lost. Seeing the line: Which is wrong since udev already should be installed. Why this happened i have no idea.
/Tor
Juicer, my fault on the udev part. The ps command wont show anything on Bubba. It runs in another way than on Debian Etch where i looked.
The reason this failed seemed to be that udev, the application responsible for creating device nodes, such as /dev/hda2, for devices in the system (The replacement for devfs), somehow got lost. Seeing the line:
Code: Select all
The following NEW packages will be installed:
udev
/Tor
Co-founder OpenProducts and Ex Excito Developer
Hi
I looked at my own system and found the same problem, no swap.
Had everything setup minimized enough not experience any memory problems.
Ubi, you are correct. I have tried some packages and one of them deinstalled udev.
I don't know which one any more, maybe when i tried to get gmailfs working.
So taking the problem as an opportunity to upgrade to etch.
cheers
Eek
I looked at my own system and found the same problem, no swap.
Had everything setup minimized enough not experience any memory problems.
Ubi, you are correct. I have tried some packages and one of them deinstalled udev.
I don't know which one any more, maybe when i tried to get gmailfs working.
So taking the problem as an opportunity to upgrade to etch.
cheers
Eek