Bekijk de volledige versie : 1 USB and 1 HDD in the same time. Reboot
Example:
I have HDD on disc0 and USB stick on disc1
/dev/discs/disc0/part1 on /tmp/harddisk type ext3 (rw,noatime)
/dev/discs/disc1/part1 on /tmp/harddisk/part1 type vfat (rw,noatime)
After the reboot, the devices are " switched" bettwin. HDD become disc1 and USB become disc0
How can i avoid this ? I wish to use one (or two) USB devices INSIDE of the router (soldered).I want to be sure that disc0 stays disc0 and so on.
Any ideeas ?
Sorry for my english.
Im using Oleg's firmare 1.9.2.7-8
Thanks to all !
Do you have the hdd connected to the lower usb-port?
and the usb-stick connected to the upper usb-port?
In my experience, the lower usb-port get accessed before the upper port.
this might help.
Do you have the hdd connected to the lower usb-port?
and the usb-stick connected to the upper usb-port?
In my experience, the lower usb-port get accessed before the upper port.
this might help.
You have right, now it's working !!!
Thanks !!!
Now i have another problem.My 2nd USB device is automatically mounted like this:
/dev/discs/disc1/part1 on /tmp/harddisk/part1
i would like to be like this:
/dev/discs/disc1/part1 on /opt
I've tryed to write this code in post-boot, but doesn't work :
#!/bin/sh
dropbear
umount /tmp/harddisk/part1
mount /dev/discs/disc1/part1 /opt
i=0
while [ $i -le 30 ]
do
if [ -d /opt/etc ]
then
break
fi
sleep 1
i=`expr $i + 1`
done
swapon /dev/discs/disc0/part2
/opt/etc/init.d/rc.unslung
Any ideea?
create /etc/fstab: http://wl500g.info/showthread.php?t=12295
create /etc/fstab: http://wl500g.info/showthread.php?t=12295
Great! You're a genius!
Another think
It is usefull/possible to use a USB stick (not HDD) for making swap ?
Thank you again!
possible but not useful.
usb flash has limited number of recording cyles. According to the postings of the people in this forum swap partition on usb stick lives about half a year.
possible but not useful.
usb flash has limited number of recording cyles. According to the postings of the people in this forum swap partition on usb stick lives about half a year.
Maybe. But the waranty period of this kind of devices is 5 years.
So, somehow, i don't care.I just must pay attention at speed.And i think that "migo" it's one of the mots quick common devices.
Thansk again !!!
Hi,
yeah, usb-swap works great.. it's faster than the swap on the harddisk (mostly due to access-times)
BUT, (big but !)
like al37919 already said,
Mine lived for about half a year, due to the limited write-cycles.
then you start to get all kinds of weird error messages, and it took me a while to understand that my swap was breaking down..
When I switched to swap on harddisk again, the error messages where gone.
I've tryed to write down the code for fstab, but i don't know how to do-it.
Could some of you have some time to teach me ?
I have this error:
[admin@heavensdoor root]$ cat > /etc/fstab < ___eof
-sh: cannot open ___eof: No such file
after, i try like this :
[admin@heavensdoor root]$ cat > /etc/fstab
and it's free to edit, but i don't know how to save. I think something is wrong.
Can you help me, pls ?
The " step by step " code would be very helpfull for me
newbiefan
03-03-2008, 21:55
well, should be easy, but you must read a bit more anyway.....
Ok, provided you use telnet or putty: (if you don't know it, you must read more)
open a console on your router and start with 'vi /tmp/etc/fstab'
Consider that vi accept datas when pressing 'i' at first.
Input the attached file below and adjust the file to your needs.
(Remove extension txt!)
exit vi with 'ESC :wq'
start again 'vi /tmp/local/.files' and input just one line
'/tmp/etc/fstab'
exit vi with 'ESC :wq'
remove any mount command from post-boot!!
now perform a: 'flashfs save && flashfs commit && flashfs enable && reboot'
done....
Super, it works
I didn't know that the file exists, allready.
Thanks !
newbiefan
04-03-2008, 21:23
Super, it works
I didn't know that the file exists, allready.
Thanks !
Well, as long as you are using samba and/or ftp server of your asus, your system is working. When you disable samba and/or ftp server you'll get a problem again - your hdd will not be detected.
Just add to your post-boot after dropbear:
#when samba and/or ftp server is disabled in webif
if [ ! -d /dev/discs ] ; then
insmod scsi_mod && insmod sd_mod && insmod usb-storage
fi
Don't forget to store it again with: flashfs save && flashfs commit && flashfs enable && reboot
Now your system should work proper.......
it was exactelly like this.Now i can see the utility of this:
if [ ! -d /dev/discs ] ; then
insmod scsi_mod && insmod sd_mod && insmod usb-storage
fi
Super! Great support!
Thank you again!