For all:
The behaviour of rc.unslung changed!!!
There is a start/stop parameter required for all new startup Scripts.
Check all startup scripts in /opt/etc/init.d/
Use the scripts from the howto.
wengi
Printable View
For all:
The behaviour of rc.unslung changed!!!
There is a start/stop parameter required for all new startup Scripts.
Check all startup scripts in /opt/etc/init.d/
Use the scripts from the howto.
wengi
Hi, wpte.
I've had problems too, when I switched to the newer firmware. In the end it turned out I've made some faults when configuring things.
- The newer firmware doesn't need to start the scsi mod for usb drives. It's in the original firmware already and you can enable it through the standard website of the asus.
- mounting is done through fstab
- the only content the post-boot file now has is 'dropbear' to start dropbear, as the unslung file is started in the post-mount file. If you think the post-mount file doesn't work, take a look a the rc.unslung file. There might be a problem there. (and remind to start it with a parameter, because its behaviour changed in order to gracefully stop and restart services/daemons.)
The problems I've had are in : http://www.wl500g.info/showthread.php?t=14255
And the solutions are in: http://wl500g.info/showthread.php?t=13785
(I had the syslogd and xinetd startup files mixed which resulted in strange errors and writing 4gb's of a log on a reboot.)
I still did not manage to run xinetd properly, but currently I don't have a service/daemon depending on that one.
I must say, after I've had these problems sorted out its stable, and best of all, data is 'more' secure after reboot/power failure/disconnect.
I'll start reading then;)
I don't like the firmware to do the mods, it feels a bit less in control then starting them yourself.
I also made some changes to the check before the disk mount.
I set them after every 10 mounts a quick check (fsck)
and after 50 mounts a full check (e2fsck -fy)
:)
I also made the disk spin down, wich is quite hard because every few moments mysql wants to read something... but sometimes it keeps quiet for 2 min, fair enough:D
well.. i run the swap now on a usb disk wich is actually faster than my hdd. also i set the limit on 1min, so if nothing accessed the drive in 1min, it spins down.
in the night it sometimes start again for cron wich is regulairy updating my websites an backing them up. (incredimental :p )
but apart from that, the drive spins down, only when pcs are on it spins up quite a lot :)
i changed a bit on the boot scripts now, just the final touch :)
but im not going to use the firmware mount, i like the manual one :D
also, i think fsck is less complete scanning than e2fsck because its done in 5min and the e2fsck in 30 :p
Hi Serpent, I wish I'd know..
It seems that the service starts (there's a process), But the services that have to be started by xinetd (eg. vsftpd) will not start.
I'm 99% sure I've misconfigured something, but haven't had the the time to haunt that problem..
(problem for me was that I really need ftp, work related, so I installed proftpd, not as fast, but at least I have a FTP service running)
it might be something I don't see with my basic *nix knowledge, therefore I post the S10xinetd file (/opt/etc/init.d)
and my unslungCode:#! /bin/sh
#
# Startup script for xinetd
#
prefix=/opt
sbindir=${prefix}/sbin
NAME=xinetd
DAEMON=${sbindir}/${NAME}
DESC="xinetd"
PIDFILE="/var/run/xinetd.pid"
OPTIONS="-pidfile $PIDFILE"
CONFDIR="/opt/etc/xinetd.d"
# installation check
test -x ${DAEMON} || exit 0
case "$1" in
start)
if [ -z "`pidof ${NAME}`" ] ; then
printf "Starting ${DESC}: "
${DAEMON} ${OPTIONS}
printf "${NAME}.\n"
fi
;;
stop)
if [ -n "`pidof ${NAME}`" ]; then
printf "Stopping ${DESC}: "
kill -SIGTERM `cat $PIDFILE`
printf "${NAME}.\n"
for i in ${CONFDIR}/* ; do
if [ -n "`grep "^[[:space:]]*disable[[:space:]]*=[[:space:]]*no"
${i}`" ] ; then
daemon="`basename $(awk -F=
'/^[[:space:]]*server[[:space:]]*=[[:space:]]*.*/{print $2}' ${i})`"
printf "Stopping ${daemon}: "
kill "`pidof ${daemon}`" > /dev/null 2>&1
printf "${daemon}.\n"
fi
done
fi
;;
reload|reconfigure)
if [ -n "`pidof ${NAME}`" ]; then
printf "Reloading ${DESC}: "
kill -SIGHUP `cat $PIDFILE`
printf "${NAME}.\n"
fi
;;
restart|force-reload)
$0 stop
sleep 1
$0 start
;;
*)
printf "Usage: $0
{start|stop|reload|reconfigure|restart|force-reload}\n" >&2
exit
;;
esac
exit 0
right now.. I removed the vsftpd package, and the one in the firmware is also not working.Code:#! /bin/sh
# Start/stop all init scripts in /opt/etc/init.d
# starting them in numerical order and
# stopping them in reverse numerical order
#
if [ $# -ne 1 ]; then
printf "Usage: $0 {start|stop}\n" >&2
exit 1
fi
daemons=`echo $(/usr/bin/dirname $0)/S??*`
[ $1 = "stop" ] && daemons=`echo $daemons | /usr/bin/tr " " "\n" |
/usr/bin/sort -r`
for i in $daemons; do
# Ignore dangling symlinks (if any).
[ ! -f "$i" ] && continue
# Write to syslog
logger -t rc.unslung "$1 service $i"
case "$i" in
*.sh)
# Source shell script for speed.
(
trap - INT QUIT TSTP
set $1
. $i
)
;;
*)
# No sh extension, so fork subprocess.
$i $1
;;
esac
done
I've followed wengi's (section 10a from his tut.) advice on how to start 'something' (samba) with xinetd, but that didn't work, Samba wouldn't run, so I reverted to my old settings and samba did work again.
Nice.. usb-swap-key is so much faster, I'm curious how long it survives in your setup. I've had it to, after 5-6 month I got all kinds of error which I couldn't explain.. switched the swap back to the hdd, and all the problems where gone... But you're right, the system is much faster with such a swap.
same here. but it seems that somehow the 'quality' of the flash mem is affected. (which is a known characteristic of flash mem when overwritten thousands/milllions of times)Quote:
but I could not find errors on it while checking it, so I guess it's ok
Ah well, I'm now totally on your script wengi:)
I still got some modified parts to keep it running in my way.
I also used the firmware scsi mod.
now I have only one problem, I can''t get my FTP to working because I mount part3 as /mnt
this was the original script to let the ftp work:
now I have this configuration:Quote:
#Mount for ftp
mount /dev/discs/disc0/part2 /tmp/mnt/disc0_2
mount /dev/discs/disc0/part3 /tmp/mnt/disc0_3
I expect to use the same options as the other mounts, but it''s not workingQuote:
#device Mountpoint FStype Options Dump Pass#
/dev/discs/disc0/part1 none swap sw 0 0
/dev/discs/disc0/part2 /opt ext3 rw,noatime 1 1
/dev/discs/disc0/part3 /mnt ext3 rw,noatime 1 1
/dev/discs/disc0/part2 /tmp/mnt/disc0_2 ext3 rw,noatime 1 1
/dev/discs/disc0/part3 /tmp/mnt/disc0_3 ext3 rw,noatime 1 1
/dev/discs/disc1/part1 /tmp/mnt/disc1 ext3 rw,noatime 1 1
The mounting stops at /tmp/mnt/disc0_2.
so I get this:
there should be 2 ways to solve this problem:Quote:
Filesystem 1k-blocks Used Available Use% Mounted on
/dev/root 3072 3072 0 100% /
/dev/discs/disc0/part2 3850320 294316 3360416 8% /opt
/dev/discs/disc0/part3 476331024 118224836 333909892 26% /mnt
1 - get the mounts right
2 - make the vsftpd work on /mnt and /opt
the 2nd option is just a giant mystery for me how to do it:p
it must be some nvram... but how do you know witch:confused:
thanks wengi for the scripts, they are working better than the old ones:)
Hi,
check your fstab! Why do you mount to /mnt?
If you can give me a clean description of what you want to be mounted to where i can give you advice...
Normaly the fstab of my howto should be ok for your config.
I didn't try the ftp but maybe the ftpd will not follow the symlink /tmp/harddisk.
Try to change the rootdir in the ftp config in a second step.
wengi
EDIT: No news on transmission.
As far as I know the ftpd won't start as long no harddrives are mounted on /tmp/mnt
it's a value that can not be changed in the web admin as far as I know.
ok:
I want to mount the opt partition to: /opt and /tmp/mnt/disc0_2
the data partition to: /mnt and /tmp/mnt/disc0_3
I mount the data partition to /mnt because it's shorter (and I'm a bit lazy:p)
and I showed you my fstab in the previous post, I tought it should be done like that;)
Can you mount the partitions by hand?
Try to create the directories
/tmp/mnt/disc0_2
/tmp/mnt/disc0_3
/tmp/mnt/disc1
before mounting.
As far as i know using fstab the process itself should create the dirs before mounting, but maybe i am wrong or there is a bug...?!
wengi
after the disc check in pre-boot I have now 2 mkdirs to create both ftp dirs:)
then I have in fstab the mountpoints and it works:D
a bit stupid that I couldn''t figure the mkidir myself out:oQuote:
Filesystem 1k-blocks Used Available Use% Mounted on
/dev/root 3072 3072 0 100% /
/dev/discs/disc0/part2 3850320 541052 3113680 15% /opt
/dev/discs/disc0/part3 476331024 118551016 333583712 26% /mnt
/dev/discs/disc0/part2 3850320 541052 3113680 15% /tmp/mnt/disc0_2
/dev/discs/disc0/part3 476331024 118551016 333583712 26% /tmp/mnt/disc0_3
well, it totally works now:)
I do think it scans the drives double now, but hey, then you''re sure no errors are left;)
I have a problem deleting what i download with transmission..
I need admin rights to do it.. How do i get this??
Hi,
I just finished setting up WL500gP V2 + HDD using Wengi's tutorial, great job.
It was the first time i was working with linux, but following this tutorial, i'm starting to understand how linux works, so thanks for that too.
Firmware: Oleg 1.9.2.7-10
Followed steps: 1, 2, 3, 4a, 4b, 5
on this step i got this:
don't know if it can cause any problemsQuote:
admin@WL-500gP root]$ wget http://ipkg.nslu2-linux.org/feeds/op...3-9_mipsel.ipk
Connecting to ipkg.nslu2-linux.org[140.211.169.169]:80
wget: server returned error 404: HTTP/1.1 404 Not Found
[admin@WL-500gP root]$ ipkg.sh install ipkg-opt_0.99.163-9_mipsel.ipk
File not found ipkg-opt_0.99.163-9_mipsel.ipk
when running ipkg list_installed, i get:
on this step it was the only errorQuote:
[admin@blechbuechse ipkg]$ ipkg list_installed
ipkg-opt - 0.99.149-2 - The Itsy Package Manager
uclibc-opt - 0.9.28-13
next steps: 8, 9, 10a - no errors
Now, i select the torrent for download, i have it in "source" dir, "Push" in transmission, i have it as ACTIVE, but nothing happens:confused:
Whan the torrent is active, the window looks like this:
Quote:
THE MENU
/opt/share/www/cgi-bin/transmission.cgi: kill: 9: (4000) - No such process
OOo_2.4.1rc1_20080523_SolarisSparc_install_en-US.tar.gz started Start: 29 May 00:12 Active status
Unable to find recent transfer stats in syslog
00:12:23 up 41 min, load average: 0.24, 0.13, 0.08
If I select "Info" i get:
Maybe i did something wrong, the torrent is: OOo_2.4.1rc1_20080523_SolarisSparc_install_en-US.tar.gz.torrent, and it' working.Quote:
Not a regular file (/tmp/harddisk/torrent/work/OOo_2.4.1rc1_20080523_SolarisSparc_install_en-US.tar.gz/OOo_2.4.1rc1_20080523_SolarisSparc_install_en-US.tar.gz.torrent)
Transmission 0.82 (r) - http://transmission.m0k.org/
Failed opening torrent file `/tmp/harddisk/torrent/work/OOo_2.4.1rc1_20080523_SolarisSparc_install_en-US.tar.gz/OOo_2.4.1rc1_20080523_SolarisSparc_install_en-US.tar.gz.torrent'
Not a regular file (/tmp/harddisk/torrent/work/OOo_2.4.1rc1_20080523_SolarisSparc_install_en-US.tar.gz/OOo_2.4.1rc1_20080523_SolarisSparc_install_en-US.tar.gz.torrent)
Thank you in advance!
PS: english is not my native language, so sorry for my writting mistakes :D
what kind of windows do you use?
do you have guest account activated?:rolleyes:
@bogd_A
if you get a wget error, try it again, if you get it again, wait an hour, the server might be offline.
I don''t know if you continued to install everything, that''s why transmission might be acting weird.
note that due to some recent updates on transmission some strange behaviour happens to some ppl:)
ipkg-opt was updated on 24.05.2008:
http://nslu2-linux.dyoung-mirror.net...-10_mipsel.ipk
I will update the HowTo.
wengi
Edit:
@bogd_A:
You are on an very old ipkg-opt installation now. Do again the wget and install stuff of ipkg-opt. Do a "ipkg update && ipkg upgrade" after this.
I hope this will switch you to the new repositories. This will also update your transmission to 1.21.
That was the problem, now everything works as it should, thank you for your support.Quote:
Edit:
@bogd_A:
You are on an very old ipkg-opt installation now. Do again the wget and install stuff of ipkg-opt. Do a "ipkg update && ipkg upgrade" after this.
I hope this will switch you to the new repositories. This will also update your transmission to 1.21
But there is one small issue: as said by nunbaggi, when trying to remove from the webinterface, a downloaded torrent, I get "Can only remove suspended torrents! Edit transmission.conf to FORCE_REMOVE. "
In transmission.conf - Force_remove is set to "YES"
The status of downloadet torrent is "DONE"
As for SAMBA it's enabled from the router's webinterface.
Firmware: 1.9.2.7-10
Regarding samba I have another issue, I can acces souce, targhet, work from a Vista OS, but when trying to acces it from XP OS, i get a logon box with user: WL-500/guest, and password :(
I am not using the Force_remove. I use ssh or samba.
And i do not have a torrent to test this atm.
But read the help (Help button in WIf).
I think you have to press purge and remove. But maybe i am wrong....
wengi
PS: http://www.nslu2-linux.org/wiki/Optware/Transmission
Hi.
I have a big prolem now.
Everything works fine until last evening.
Part2 become full. :(. This was for /otp...
Every process gives input/output error.
After restart this was in the log:
Quote:
Jan 1 01:00:18 kernel: SCSI disk error : host 0 channel 0 id 0 lun 0 return code = 8000002
Jan 1 01:00:18 kernel: Current sd08:01: sns = 70 4
Jan 1 01:00:18 kernel: ASC=4b ASCQ= 0
Jan 1 01:00:18 kernel: Raw sense data:0x70 0x00 0x04 0x00 0x00 0x00 0x00 0x0a 0x00 0x00 0x00 0x00 0x4b 0x00 0x00 0x00 0x00 0x00
Jan 1 01:00:18 kernel: I/O error: dev 08:01, sector 0
Jan 1 01:00:18 kernel: Adding Swap: 506008k swap-space (priority -1)
May 31 09:57:19 e2fsck: e2fsck: while trying to open /dev/discs/disc0/part2
May 31 09:57:19 e2fsck: /dev/discs/disc0/part2:
May 31 09:57:19 e2fsck: The superblock could not be read or does not describe a correct ext2
May 31 09:57:19 e2fsck: filesystem. If the device is valid and it really contains an ext2
May 31 09:57:19 e2fsck: filesystem (and not swap or ufs or something else), then the superblock
May 31 09:57:19 e2fsck: is corrupt, and you might try running e2fsck with an alternate superblock:
May 31 09:57:19 e2fsck: e2fsck -b 8193 <device>
May 31 09:57:19 kernel: SCSI disk error : host 0 channel 0 id 0 lun 0 return code = 8000002
May 31 09:57:19 kernel: Current sd08:03: sns = 70 4
May 31 09:57:19 kernel: ASC=4b ASCQ= 0
May 31 09:57:19 kernel: Raw sense data:0x70 0x00 0x04 0x00 0x00 0x00 0x00 0x0a 0x00 0x00 0x00 0x00 0x4b 0x00 0x00 0x00 0x00 0x00
May 31 09:57:19 kernel: I/O error: dev 08:03, sector 0
May 31 09:57:19 kernel: SCSI disk error : host 0 channel 0 id 0 lun 0 return code = 8000002
May 31 09:57:19 kernel: Current sd08:03: sns = 70 4
May 31 09:57:19 kernel: ASC=4b ASCQ= 0
May 31 09:57:19 kernel: Raw sense data:0x70 0x00 0x04 0x00 0x00 0x00 0x00 0x0a 0x00 0x00 0x00 0x00 0x4b 0x00 0x00 0x00 0x00 0x00
May 31 09:57:19 kernel: I/O error: dev 08:03, sector 2
May 31 09:57:19 e2fsck: e2fsck: while trying to open /dev/discs/disc0/part3
May 31 09:57:19 e2fsck: Could this be a zero-length partition?
May 31 09:57:19 kernel: SCSI disk error : host 0 channel 0 id 0 lun 0 return code = 8000002
May 31 09:57:19 kernel: Current sd08:01: sns = 70 4
May 31 09:57:19 kernel: ASC=4b ASCQ= 0
May 31 09:57:19 kernel: Raw sense data:0x70 0x00 0x04 0x00 0x00 0x00 0x00 0x0a 0x00 0x00 0x00 0x00 0x4b 0x00 0x00 0x00 0x00 0x00
May 31 09:57:19 kernel: I/O error: dev 08:01, sector 0
May 31 09:57:19 kernel: SCSI disk error : host 0 channel 0 id 0 lun 0 return code = 8000002
May 31 09:57:19 kernel: Current sd08:01: sns = 70 4
May 31 09:57:19 kernel: ASC=4b ASCQ= 0
May 31 09:57:19 kernel: Raw sense data:0x70 0x00 0x04 0x00 0x00 0x00 0x00 0x0a 0x00 0x00 0x00 0x00 0x4b 0x00 0x00 0x00 0x00 0x00
May 31 09:57:19 kernel: I/O error: dev 08:01, sector 8
May 31 09:57:19 kernel: SCSI disk error : host 0 channel 0 id 0 lun 0 return code = 8000002
May 31 09:57:19 kernel: Current sd08:02: sns = 70 4
May 31 09:57:19 kernel: ASC=4b ASCQ= 0
May 31 09:57:19 kernel: Raw sense data:0x70 0x00 0x04 0x00 0x00 0x00 0x00 0x0a 0x00 0x00 0x00 0x00 0x4b 0x00 0x00 0x00 0x00 0x00
May 31 09:57:19 kernel: I/O error: dev 08:02, sector 0
May 31 09:57:19 kernel: SCSI disk error : host 0 channel 0 id 0 lun 0 return code = 8000002
May 31 09:57:19 kernel: Current sd08:03: sns = 70 4
May 31 09:57:19 kernel: ASC=4b ASCQ= 0
May 31 09:57:19 kernel: Raw sense data:0x70 0x00 0x04 0x00 0x00 0x00 0x00 0x0a 0x00 0x00 0x00 0x00 0x4b 0x00 0x00 0x00 0x00 0x00
May 31 09:57:19 kernel: I/O error: dev 08:03, sector 2
May 31 09:57:19 kernel: EXT3-fs: unable to read superblock
What shuld I do now?
Thanks for your help in advance.
MrPeeth
Hi,
is /opt really full? Didnt think this is possible with ipkg packages. Or did you copy other stuff to /opt?
The other possibility is that the hdd has a prob. (e.g. bad sectors).
Did you try to use the alternative superblock?
wengi
The Torrents are in target dir, Remove (mark a torrent for removal) and Purge (delete the torrent and its file), can be used only for unfinished (suspended) torrents only, and that's why it didn't worked.
When I try to remove from samba I get: "You need permission to perform this action" - in VISTA OS
Can you tell me the command for delete using ssh?
And anothet issue:
I can't acces the torrent dir from a XP OS, only from Vista OS, can you help me?
In XP shows an logon window with use: WL-500gp\Guest, and password, nothing like this in Vista :confused:
For dropbear I needed to satisfy the following requirements.
Disable password access for remote connections
Open port 443 and 2222 for remote connections (443 for when 2222 is blocked)
Allow password access on local connections
Don't open up port 22 for remote connections
I found that you can run multiple dropbear servers and they will co-exist. Here is how I set it up.
The first is for post-boot. The only additional parameter here is -P which defines the pid file location. I renamed it otherwise the second one will overwrite the first rather than appending to it.Code:[shinji@WL-001E8C3E002C sbin]$ cat post-boot
#! /bin/sh
dropbear -P /var/run/dropbear-local.pid
[shinji@WL-001E8C3E002C sbin]$ cat post-mount
#! /bin/sh
dropbear -b /opt/etc/motd -g -p 2222 -P /var/run/dropbear-remote.pid
/opt/etc/init.d/rc.unslung start
The second is post-mount. Note that it could of been put in post-boot as well but I put something into the command line that needs a file from the external device. I will explain each part.
-b defines a banner file to present before login finishes. It will be shown after the username is sent and before the password is requested. It is set to /opt/etc/motd right now so it is on the mounted device. This switch is optional and can be left out. If it is removed then it is save to move the whole remaining command-line to post-boot instead.
-g disables password logins for the "root" user
-s disables password logins globally (all users)
-p defines a port to listen to. You can use this parameter up to 10 times.
Note that the password-less login bit only affects that server. The one running on port 22 still accepts a password so I can still access it locally even if I lose my key.
EDIT: I should add that I recently added a user for the purpose of sftp access by a remote website. I change the original -s to -g. It will still prompt for a password but it will flat out deny it. My sftp user has /opt/libexec/sftp-server setup as the shell so right now ssh brings up a blank screen that they can do nothing at. You can change the -g (in bold above) to -s and it will deny all password logins for that server process.
EDIT: Here is an alternative to the above setup. This is one I have been using lately. The advantage here is that both servers are running immediately and you don't have to wait for the drive to mount for the external one to be usable.
Note I used a banner that is in the /etc folder. To keep it persistent between reboots you have to make sure to save it as part of your flashfs (instructions in the main post) by adding it to your /usr/local/.files file.Code:[shinji@WL-001E8C3DFF31 sbin]$ cat post-boot
#! /bin/sh
dropbear -P /var/run/dropbear-local.pid
dropbear -s -p 2222 -P /var/run/dropbear-remote.pid -b /etc/banner
Now the firewall...
I set it up so that ports 443 and 2222 would be externally accessable. Note that they both route to the same server running on port 2222. 443 is only there for cases where I need to route through a strict firewall that only allows http, https, and standard ssh connections. If you changed the port number in the command for the second server then replace 2222 with your port number. If you don't want port 443 open then remove the line in bold.Code:[shinji@WL-001E8C3E002C sbin]$ cat post-firewall
#! /bin/sh
iptables -D INPUT -j DROP
iptables -t nat -A PREROUTING -i vlan1 -p tcp --dport 443 -j DNAT --to-destination 192.168.1.1:2222
iptables -t nat -A PREROUTING -i vlan1 -p tcp --dport 2222 -j DNAT --to-destination 192.168.1.1:2222
iptables -A INPUT -p tcp -m tcp -d 192.168.1.1 --dport 2222 -j ACCEPT
iptables -A INPUT -j DROP
If you setup everything right then you will see the following when you run ps axf (if you installed procps)
Note the 2 dropbear servers running.Code:[shinji@WL-001E8C3E002C root]$ ps axf
PID TTY STAT TIME COMMAND
1 ? S 0:01 /sbin/init
2 ? S 0:00 [keventd]
3 ? SN 1:07 [ksoftirqd_CPU0]
4 ? S 0:00 [kswapd]
5 ? S 0:00 [bdflush]
6 ? S 0:00 [kupdated]
7 ? S 0:00 [mtdblockd]
58 ? S 0:00 telnetd
64 ? S 0:00 httpd vlan1
70 ? S 0:00 klogd
71 ? S 0:03 [dnsmasq]
73 ? Ss 0:00 nas /tmp/nas.lan.conf /tmp/nas.lan.pid lan
76 ? S 0:00 [khubd]
88 ? S 0:01 [usb-storage-0]
90 ? S 0:00 [scsi_eh_0]
114 ? Ss 0:00 watchdog
117 ? Ss 0:00 \_ ntp
116 ? S 0:00 radvd
124 ? S 0:00 dropbear -P /var/run/dropbear-local.pid
146 ? S 0:00 [kjournald]
147 ? S 0:00 [kjournald]
149 ? Ss 0:04 /usr/sbin/nmbd -D
151 ? Ss 0:00 /usr/sbin/smbd -D
155 ? S 0:00 dropbear -b /opt/etc/motd -s -p 2222 -P /var/run/dropbear-remote.pid
4238 ? Ss 0:00 \_ dropbear -b /opt/etc/motd -s -p 2222 -P /var/run/dropbear-remote.pid
4239 pts/0 Ss 0:00 \_ -sh
4242 pts/0 R+ 0:00 \_ ps axf
180 ? S 0:00 /sbin/syslogd -m 0 -O /opt/var/log/syslog.log -S -l 7 -s 0
186 ? Ss 0:00 /opt/sbin/cron
4176 ? S 0:00 upnp -D -L br0 -W vlan1
Right now if someone accesses the router remotely then they will get the following.
This would make it kinda fruitless to try to gain access that way unless there was an exploit for the dropbear server.Code:compton:/home/shinji257> ssh -o Port=2222 shinji@xx.xx.xx.xx
..:: Elite Systems Remote SSH Access ::..
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
This is a restricted server.
Unauthorized access is strictly prohibited.
ALL CONNECTIONS ARE LOGGED.
Permission denied (publickey).
Hi Wengi!
Thx, 4 your answer.
"df" said that te part2is full.
I have discovered that transmission put temp datas there in /share/www dir.
the part3 seems to be working after 1 day OFF.
I turned on the hdd while router was was working.
Here is the log:
Here is the info about the hdd now.Quote:
Jun 1 10:36:50 e2fsck: e2fsck: while trying to open /dev/discs/disc0/part2
Jun 1 10:36:50 e2fsck: /dev/discs/disc0/part2:
Jun 1 10:36:50 e2fsck: The superblock could not be read or does not describe a correct ext2
Jun 1 10:36:50 e2fsck: filesystem. If the device is valid and it really contains an ext2
Jun 1 10:36:50 e2fsck: filesystem (and not swap or ufs or something else), then the superblock
Jun 1 10:36:50 e2fsck: is corrupt, and you might try running e2fsck with an alternate superblock:
Jun 1 10:36:50 e2fsck: e2fsck -b 8193 <device>
Jun 1 10:36:50 e2fsck: /dev/discs/disc0/part3: recovering journal
Jun 1 10:37:33 kernel: SCSI disk error : host 0 channel 0 id 0 lun 0 return code = 8000002
Jun 1 10:37:33 kernel: Current sd08:03: sns = 70 4
Jun 1 10:37:33 kernel: ASC=4b ASCQ= 0
Jun 1 10:37:33 kernel: Raw sense data:0x70 0x00 0x04 0x00 0x00 0x00 0x00 0x0a 0x00 0x00 0x00 0x00 0x4b 0x00 0x00 0x00 0x00 0x00
Jun 1 10:37:33 kernel: I/O error: dev 08:03, sector 8650752
Jun 1 10:37:34 kernel: SCSI disk error : host 0 channel 0 id 0 lun 0 return code = 8000002
Jun 1 10:37:34 kernel: Current sd08:03: sns = 70 4
Jun 1 10:37:34 kernel: ASC=4b ASCQ= 0
Jun 1 10:37:34 kernel: Raw sense data:0x70 0x00 0x04 0x00 0x00 0x00 0x00 0x0a 0x00 0x00 0x00 0x00 0x4b 0x00 0x00 0x00 0x00 0x00
Jun 1 10:37:34 kernel: I/O error: dev 08:03, sector 24232
Jun 1 10:37:34 kernel: SCSI disk error : host 0 channel 0 id 0 lun 0 return code = 8000002
Jun 1 10:37:34 kernel: Current sd08:03: sns = 70 4
Jun 1 10:37:34 kernel: ASC=4b ASCQ= 0
Jun 1 10:37:34 kernel: Raw sense data:0x70 0x00 0x04 0x00 0x00 0x00 0x00 0x0a 0x00 0x00 0x00 0x00 0x4b 0x00 0x00 0x00 0x00 0x00
Jun 1 10:37:34 kernel: I/O error: dev 08:03, sector 24234
Jun 1 10:37:34 kernel: SCSI disk error : host 0 channel 0 id 0 lun 0 return code = 8000002
Jun 1 10:37:34 kernel: Current sd08:03: sns = 70 4
Jun 1 10:37:34 kernel: ASC=4b ASCQ= 0
Jun 1 10:37:34 kernel: Raw sense data:0x70 0x00 0x04 0x00 0x00 0x00 0x00 0x0a 0x00 0x00 0x00 0x00 0x4b 0x00 0x00 0x00 0x00 0x00
Jun 1 10:37:34 kernel: I/O error: dev 08:03, sector 24236
Jun 1 10:37:34 e2fsck: e2fsck: while reading block 3029
Jun 1 10:37:34 e2fsck: JBD: Failed to read block at offset 2495
Jun 1 10:37:34 e2fsck: JBD: IO error -5 recovering block 2495 in log
Jun 1 10:37:40 e2fsck: e2fsck: while recovering ext3 journal of /dev/discs/disc0/part3
Jun 1 10:37:40 kernel: kjournald starting. Commit interval 5 seconds
Jun 1 10:37:40 kernel: EXT3-fs warning: checktime reached, running e2fsck is recommended
Jun 1 10:37:40 kernel: EXT3 FS 2.4-0.9.19, 19 August 2002 on sd(8,3), internal journal
Jun 1 10:37:40 kernel: EXT3-fs: recovery complete.
Jun 1 10:37:40 kernel: EXT3-fs: mounted filesystem with ordered data mode.
Jun 1 10:37:40 USB storage: ext3 fs at /dev/discs/disc0/part3 mounted to /tmp/mnt/disc0_3
Now I have no access to part2, so I cannot check which dir is full.Quote:
[admin@PSQ10 root]$ df
Filesystem 1k-blocks Used Available Use% Mounted on
/dev/root 3072 3072 0 100% /
/dev/discs/disc0/part3 152349444 133157204 11453328 92% /tmp/mnt/disc0_3
[admin@PSQ10 root]$ fdisk -l
Disk /dev/scsi/host0/bus0/target0/lun0/disc: 160.0 GB, 160041885696 bytes
255 heads, 63 sectors/track, 19457 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Device Boot Start End Blocks Id System
/dev/scsi/host0/bus0/target0/lun0/part1 1 63 506016 82 Linux swap
/dev/scsi/host0/bus0/target0/lun0/part2 64 188 1004062+ 83 Linux
/dev/scsi/host0/bus0/target0/lun0/part3 189 19457 154778242+ 83 Linux
Part3 didn't mounted to where fstab describe. :(Quote:
[admin@PSQ10 root]$ vi /etc/fstab
#device Mountpoint FStype Options Dump Pass#
/dev/discs/disc0/part1 none swap sw 0 0
/dev/discs/disc0/part2 /opt ext3 rw,noatime 1 1
/dev/discs/disc0/part3 /tmp/harddisk ext3 rw,noatime 1 1
I started my Linux with your tutorial, so can you help me in the alt. superblock or bad sector check?
FW vers.: 1.9.2.7-10
Thank:
MrPeeth
Hello everyone :)
@MrPeeth:
transmission should not put temp data to /opt !!! Please check your transmission.conf. What is your work-directory?
Regarding the superblock you should read your own post :)You should tryCode:May 31 09:57:19 e2fsck: is corrupt, and you might try running e2fsck with an alternate superblock:
May 31 09:57:19 e2fsck: e2fsck -b 8193 <device>
BUT: If you can access your data atm: Do a backup! I think your hdd has a prob!Code:e2fsck -b 8193 /dev/discs/disc0/part2
@shinji257:
Thanks for these tips. I will link it in the howto. I am NOT able to test it....
@bogd_A:
You can e.g. use the rm command in the shell:wengiCode:rm -rf /tmp/harddisk/torrent/target/nameofyourtorrentdir
Hi Wengi!
I read errors every where that is why I did not discover the message...
This is the result:
The log growth with many error line coz e2fsck...Code:login as: admin
admin@192.168.1.1's password:
[admin@PSQ10 root]$ e2fsck -b 8193 /dev/discs/disc0/part2
e2fsck 1.38 (30-Jun-2005)
e2fsck: while trying to open /dev/discs/disc0/part2
The superblock could not be read or does not describe a correct ext2
filesystem. If the device is valid and it really contains an ext2
filesystem (and not swap or ufs or something else), then the superblock
is corrupt, and you might try running e2fsck with an alternate superblock:
e2fsck -b 8193 <device>
[admin@PSQ10 root]$
The workingdir for the transmission is:
/tmp/harddisk/torrent
I can read my datas on part3 in linux, except the /part2.
What do you think about this: delete part2, and start with a new partition and install all programs again?
or save all datas, format and test the whole disc? :eek:
Thank:
MrPeeth :confused:
Hi,
MrPeeth:
reformating and reinstalling part2 should be the fastest way.
But, as i said, i recommend a data backup. Maybe your hdd has a prob....
shinji257
thanks :)
wengi
-I followed your how too all the wayQuote:
Originally Posted by nunbaggi
I have a problem deleting what i download with transmission..
I need admin rights to do it.. How do i get this??
.Quote:
Could you please give us a bit less information...?!?
You try to delete on which way? Samba, ftp, shell, webinterface?
If samba:
Would be nice to know which samba you are using, your config aso
-i can delete using ftp, or in my computer
-
yep, only part2.
-> e2fsck -ck /dev/dis.....Code:man e2fsck
wengi
Hi Wengi!
Thx for fast reply.
I run a linux recovery on part2.
There are torrent datas in : /opt/share/cgi-bin
There are many files over 40Mb-s. Do I had any wrong settings? That is why my part2 become.
The donloaded torrents are in /tmp/harddisk/torrent/work directory, normally.
I will try to run the bad sector test.
The man command is new for me as well. :o
Thx again:
MrPeeth
add:
the really big file was: /opt/var/log/message.0 -> 7847Mb
Any idea? :)
Now I cannot find the part3 in the partiton table...
:(
Hi,
The growing of messages is the result of mixing scripts from my old and new howto.
Make sure that your files in /opt/etc/init.d/ are exactly as in my howto.
If you use an old syslog rc script it will grow your messages file until /opt is full....
If you saved all your data it would be the best to start all over again.
wengi
Thx!
Now part2 is succesfully recovered.
But, part3 cannot discover by any windows prog. :(
Linux can detect part3 with wrong superblock...
I have some important datas on that partition, so I try to make some more step to save them.
Do you have any idea?
The part3 is almost 150Gb and it was nearly full.
Norton Partition manager said: unpartitionad area. :(
Ext2FSD discover a partition, but it cannot mount to Vista
I made it like you wrote so it is an ext3 partition, isn't it?
Thanks for all help.
MrPeeth
Yes, it is ext3.
But you normaly use ext2 tools because ext3 = ext2 + journal.
Do some google search for "ext3 recover superblock".
As far as i know ext3 saves various superblocks at differentlocations...
i am not that experienced with file systems...
wengi