DSM-G600, DNS-3xx and NSA-220 Hack Forum

Unfortunately no one can be told what fun_plug is - you have to see it for yourself.

You are not logged in.

Announcement

#1 2011-01-06 16:24:22

puterboy
Member
Registered: 2008-09-18
Posts: 306

Evil - stock dns-323 firmware remakes swap on every boot

Just realized this when I couldn't figure out why my system kept loosing the swap labels.
It is important for me to use swap labels or UUID's because if I remove a hard-disk and mount a USB, I don't want to be mounting /dev/sdb1 as swap when it now is my usb partition.

Anyway, the firmware does a 'mkswap' on each boot on /dev/sda1 and /dev/sdb1 if present

I get around this problem by labeling /dev/sda4 and /dev/sdb4 and then using those labels to test for the right disk and mount swap from my rc.local rather than from /etc/fstab
e.g.
[ `e2label /dev/sda4` = "HD_a4" ] && swapon /dev/sda1
[ `e2label /dev/sdb4` = "HD_b4" ] && swapon /dev/sdb1


[NOTE IN GENERAL, if you are reloading firmware so that a USB device is mounted on reloaded boot then you probably want to be careful about staying away from partitions 1, 2, and 4, since they are likely to be overwritten]

Offline

 

Board footer

Powered by PunBB
© Copyright 2002–2010 PunBB