Good to know its working now :D
wengi
Printable View
Good to know its working now :D
wengi
may you can help me with this? http://wl500g.info/showthread.php?p=67114#post67114
Hi Aramaki,
i already read your post but unfortunately am not able to help you.
wengi
So, I've created the pair of keys for automatic login.
Then I run
and right click of my mouse in order to paste text in the putty window.Code:vi /usr/local/root/.ssh/authorized_keys
Then I pressed exactly the next keys:
... and I tried to login and didn't worked as expected.Code:[Esc]
:wq!
[Enter]
Found out later in Midnight Commander viewer that the first later from "ssh-rsa ..." was missing and I had only "sh-rsa ...".
I've added the missing "s" and it worked like a charm. :D
Don't know if it's my problem (I'm a stupid user sometimes :D) or is a bug or something. Just in case anyone gets in the same problem as me... :D
Arise,
I had a similar problem. It seems that copy-pasting from a webpage to Putty doesn't always work well. Some of my post-boot code was missing when I pasted it to putty from this tutorial. Only found out after a few reboots, of course :(
Missing parts in pasted content is mostly a result of the following:
you open vi and _forget_ to press "i" to change to insert mode.
When you paste the content is not pasted until the first i in the content appears.
example:
"this is the content" pasted in vi WITHOUT being in insert mode results in the following: "s is the content"
wengi
Wengi, thank you for your great tutorial. I've decided that it is the most detailed and started using it for connecting my usb hdd with 500gp.
Unfortunately, a have a problem after this steps:
# test if USB disc has been attached
# if not - then insert needed modules
#
# uncoment the following 4 lines if using an USB HDD.
#if [ ! -d /dev/discs ]
#then
#insmod scsi_mod && insmod sd_mod && insmod usb-storage && sleep 5s
#fi
#Wait for /opt to mount
mount /dev/discs/disc0/part2 /opt
i=0
while [ $i -le 30 ]
do
if [ -d /opt/etc ]
then
break
fi
sleep 1
i=`expr $i + 1`
done
mount /dev/discs/disc0/part3 /tmp/harddisk
# Activate swap
swapon /dev/discs/disc0/part1
# Run all active services - active means starts with S
/opt/etc/init.d/rc.unslung
I wrote it in VI editor after pressing 'i' and i saved it with :wq command.
I use 500gp like a router, so after those steps I make a command to reboot:
flashfs save && flashfs commit && flashfs enable && reboot
And then Putty says that "Fatal error (connection lost)"
I try to connect using SSH again, but also Fatal error appears (writing "network connection refused")
And i only can connect to 500gp using telnet or web.:( And when i run telnet, swap is not activated and driver is not mounted (so, startup script don't work i think) although all steps before i did according to your tutorial.
After that, i've refreshed the firmware and did everything again, but the result was the same.:confused:
Help me solve this problem please...
P.S. excuse me for my english: i've haven't any practice for a long time...
So, i've solve the problem myself: there were some mistakes in my post-boot file.
But i still have one question: how can i establish connection to my router from any place with internet. I have a real IP and using Putty thought SSH, it can't connect to router. May be i should open any ports?
Hi Hreks,
"Fatal error (connection lost)" is normal when you reboot the router.
Normaly the network connection is also droped.
Due to the Asus also is running DHCP (i suggest) all should be ok after you request a new ip (in windows: ipconfig /renew).
But good to see that you managed it yourself :D
SSH is using port 22. You have to open this port in your firewall and/or forward this port to the local ip adress of the asus.
you can also use a different port (e.g. 222) and redirect ist to 22 on local ip.
This prevents ssh scanning, which is often done in the last month.
have fun with your asus
wengi
1) Hi, Wengi, thank you for your reply, but can you give me more detailed answer?
What firewall do you mean, software or in the router?
What does it mean "forward this port to the local ip adress of the asus."
How can i use different port?
And what should i do on the computer, from which i want to connect my router(open any ports?)
Big thanks
2)WoW! I'm very happy) I've configured everything, writen in Wengi's manual. Now i have Samba, and my torrents are downloading! I can't belive:)
Wengi, really your tutorial is the best for new users of 500gp:) only one step became a problem: while activating RTC, it was error: can't create folder, permission denided.
3)And also one question: can i create my media library in \tmp\harddisk or in another folder? actually, i don't understand folders in samba according to the partitions in router, explane me please.
4) One more question: i want to make a web site in the router, considering a real IP, so i don't understand if any steps of your tutorial connected with this topic?
regards, Hreks
Hi Hreks,
i dont have that much time atm.
RTC is ONLY for WL-HDD. Others do not have a RTC.
i will come back in a few days for the other questions.
wengi
Hi,
/opt/etc/init.d/S80samba is normaly started by /opt/etc/init.d/rc.unslung.
check if rc.unslung is executable and if it is called from your post-boot.
Are the other services (/opt/etc/init.d/S*) running after restart?
wengi
rc.unslung is executable, and is being called from the post boot. I see that the one script (S80busybox_httpd) is running when I reboot since I can go to the transmission web page -
http://192.168.1.1:8008/cgi-bin/tran...gi?ACTION=List
so it make no sense why it's not running. I ran dmesg and I don't see any errors in it either.
Hi,
Is /opt/etc/init.d/S80samba executable?
What happens if you run /opt/etc/init.d/S80samba manually?
Pls. post last lines of your syslog (/opt/var/log/messages).
wengi
This is strange. I rebooted it again after I made another minor change, and now it's working. I hate it when things like that happen.
Thanks for the help though! This howto has been a great help.
First of all thx a bunch for the gr8 tut, finally I can get to my smb share without going through sftp and tranmission works so much better than e-ctorrent.
I am a bit of a linux noob though and it might be handy for the rest of you to know that if you can't get a ipkg package (mc), or some dependensies (font libraries for the bt cgi :P), or even if nano locks up (it happend to me faulty ncurses was to blame) just go too http://ipkgfind.nslu2-linux.org/.
Find the right package (always select the oleg version if possible) then copy the download link and do this in the terminal:
Or alternatively you can change your unslung package directory to the oleg versionCode:ipkg install PASTE_THE_DOWNLOAD_LINK_HERE
thenCode:nano /opt/etc/ipkg.conf
Don't forget to run ipkg update / upgrade and be amazed how outdated your system is :PCode:src unslung http://ipkg.nslu2-linux.org/feeds/optware/oleg/cross/stable
dest root /
But I do still have some question marks I hope you can help me with.
First I mosty use my smb share on the network for storage of my music so that every pc and mac all have the same songs. I haven't tried the optimisation bit yet and would like to know if I do run samba under xinetd will it be slower or something.
Furthermore I would like to get a ftp or sftp running again and was wondering if this can be run under xinetd aswell
Also if you don't have a webcam attached you can put this in the post-boot
Lasty why isn't this a sticky yet, this goes along gr8 with the macsat tutCode:rmmod videodev
transmission downloads files OK
at least I can see them with ls command
but samba shows only .torrent files and no .aviCode:drift_USA_JAP.torrent.seeding
ÐÑиÑ
Ñ Ð¯Ð¿Ð¾Ð½Ð¸Ñ Ð¿ÑоÑив Ð
Right now samba works with russian symbols OK - i can write them from XP client and see them by SMB and on Asus with ls command in appropriate way
my smb.conf
I don't remember whether I did the oleg's instructions but i guess i didQuote:
# Samba config file created using SWAT
# from 192.168.1.2 (192.168.1.2)
# Date: 2007/10/27 16:03:19
# Global parameters
[global]
client code page = 866
workgroup = BELL
netbios name = ASUS
server string =
security = SHARE
log file = /opt/var/log/samba/log.%m
max log size = 50
load printers = No
character set = 1251
dns proxy = No
guest account = admin
hosts allow = 192.168.1.
[printers]
comment = All Printers
path = /opt/var/spool/samba
printable = Yes
browseable = No
[www]
comment = HTTP server files
path = /opt/share/www
read only = No
guest ok = Yes
[torrent]
comment = torrent files
path = /tmp/harddisk/torrent
read only = No
guest ok = Yes
Can i switch everything to UTF and will it work?Quote:
nvram set lan_stp=0
nvram set usb_vfat_options=codepage=866,iocharset=cp1251
nvram set usb_ntfs_options=iocharset=cp1251
nvram set usb_smbcpage_x=866
nvram set usb_smbcset_x=1251
nvram set regulation_domain=0x00ALL
nvram commit
Sorry, but i have no idea. You will have to try.
wengi
Hi i've bean running with your tut for awhile and i noticed that file transfer rate is much slower with the custom firmeare over samba. VS the ogiginal firmware that asus supplys. But if i use the original firmware i cant get it to work with vista.
Any idea how to speed up access time? Its really slow.
The only way is to stop all other things.
Stopping transmission is most important before copying files over samba.
And running samba with xinetd if you want to use transmission is recommended.
It is not that the orig firmware is faster, it is that you normaly run more services when oleg is installed.
wengi
First of all thank you very much Wengi for this great tutorial, it should be sticked and unified with the one by marcnesium.
Today I upgraded my Wl500gP firmware with the latest from Oleg, so I decided to take a look to your toturial to change something on my filesystem...
Some note after installation:
Installed Samba2, due to problems browsing my USB disk from WinVista.
Now it's ok. Installing via ipkg Samba2 on top of original Oleg's firmware, in /opt/etc/init.d I 've found 2 samba start script:
S80samba
and S97SambaCode:#!/bin/sh
if [ -n "`pidof smbd`" ] ; then
echo "Stopping smbd:"
killall smbd
fi
if [ -n "`pidof nmbd`" ] ; then
echo "Stopping nmbd:"
killall nmbd
fi
#sleep 2
echo "Starting smbd:"
/opt/sbin/smbd -D;
echo "Starting nmbd:"
/opt/sbin/nmbd -D;
I don't know if this is a my mistake, but moving samba service from initd to xinitd, I had to remove both file.Code:#!/bin/sh
/usr/sbin/smbd -D -l /opt/var/log/smbd.log -s /opt/etc/samba/smb.conf
/usr/sbin/nmbd -D -n myasus -o -l /tmp -s /opt/etc/samba/smb.conf
One question about samba2 on xinitd: at first startup both samba services are not loaded, when I try to access my shared disk, i can see nmbd and smbd running. Are these precesses stopped after some time of inactivity ?
Another question about xinitd: I'd like to run my MediaServer (WizD) using xinitd too, to save memory space. Is it possible ?
A note about SSH autologin. This is how my login appear now:
As you can see is asking me my Passphrase instead of a complete autologin. Is this normal ?Code:Using username "root".
Authenticating with public key "MyAsus"
Passphrase for key "MyAsus":
About modules: in my WL even if not listed by lsmod, videodev is removable to gain some more Kb in memory.
More questions on the way... let me test deeply this new fw/sw combination... :D
Max
Hi,
i have not seen the S97Samba script until now. Maybe this is new with the latest oleg firmware. I could not test this until now. But running samba with xinetd needs both files to be deleted. Maybe there will have to be done some changes to the xinetd files if the conf entries of S97 are required. But i dont think so.
The processes _should_ be stopped after a timeout. In fact i sometimes see nmbd keep on running while smbd is stopped as expected. Don't know why.
WizD should also work with xinetd. But i have no idea which ports are used. This is nothing special to the oleg firmware. Simply search the inet for "wizd AND xinetd". (And write a HowTo if you managed it to work :-))
Did you define a passphrase when you saved the private key? If yes: This is the reason.
I never saw the module videodev. So thanks for the hint. It works:Strange..Code:[admin@blechbuechse init.d]$ rmmod videodev
rmmod: videodev: Success
wengi
Something strange happens running Samba2 with xinetd.
I also use xinetd for vsftp, and everytime i close an ftp session, vsftp disappear from running processes immediately, this doesn't happens with smbd and nmbd, even if I closed my last SMB connection about one hr ago... :(
About WizD, I've take a look to the startup file... too complicated for my knowledge :confused:
Max
Hi,
xinetd works for me with smbd. I never looked at the time when smbd is stopped. But it is possible that it lasts more than one hour.... Windows allways keeps smb connections open...
Does this also work on wl500gx using Oleg 1.9.2.7-7g?
I've followed steps 1 to 10 of wengi's tutorial (with the exception of 9 Transmission) but cannot get Samba2 to work. Neither smbd or nmbd can (ever) be seen to be running.
What steps should I take to solve this? I have a USB drive and a USB Hard-drive attached and both mount ok. Everything else (cron, syslog etc) seems fine.
The embedded Samba will work but I'd like to use SWAT if possible. I've looked through the posts in this thread and others and cannot see what I'm missing.
Thanks :)
this might help:
log.nmbd shows....
[2007/11/16 23:43:34, 0] source/nmbd/nmbd_responserecordsdb.c:find_response_record(235)
find_response_record: response packet id 14764 received with no matching record.
and log.smbd...
[2007/11/16 23:43:30, 0] source/smbd/server.c:main(791)
smbd version 2.2.12 started.
Copyright Andrew Tridgell and the Samba Team 1992-2002
is this a clue?
Hi,
My HowTo is working with all WL-xxx if there is a oleg firmware for it. Some little things differ, but this is mentioned in the text.
The newest firmware (-8) has some changes but this will be corrected the next days. (RTC ...)
Samba seems to be running. Could you post the result of "ps" or "ps axf".
Thanx
Hi
I stopped the firmware smbd and nmbd with killall and then ran the S80samba script. If I run ps axf immediately you can see nmbd running.
ASUS:/tmp/local/root$ /opt/etc/init.d/S80samba
Starting smbd:
Starting nmbd:
ASUS:/tmp/local/root$ ps axf
PID TTY STAT TIME COMMAND
1 ? S 0:02 /sbin/init
2 ? S 0:00 [keventd]
3 ? SN 6:35 [ksoftirqd_CPU0]
4 ? S 0:12 [kswapd]
5 ? S 0:00 [bdflush]
6 ? S 0:00 [kupdated]
7 ? S 0:00 [mtdblockd]
63 ? S 0:02 telnetd
1935 pts/0 Ss 0:00 \_ -sh
1954 pts/0 R+ 0:00 \_ ps axf
68 ? S 0:10 httpd vlan1
74 ? S 0:32 dnsmasq
76 ? S 0:00 klogd
81 ? S 0:00 [khubd]
89 ? Ss 0:00 lpd
91 ? Ss 0:00 p9100d -f /dev/usb/lp0 0
95 ? Ss 0:00 waveservermain
97 ? Ss 0:00 rcamdmain
101 ? Ss 0:00 infosvr br0
102 ? Ss 0:11 watchdog
106 ? Ss 0:00 \_ ntp
127 ? S 0:00 udhcpc -i vlan1 -p /var/run/udhcpc0.pid -s /tmp/udhcpc
129 ? S 0:02 [usb-storage-0]
130 ? S 0:00 [scsi_eh_0]
133 ? S 0:00 [kjournald]
136 ? S 4:31 [usb-storage-1]
137 ? S 0:00 [scsi_eh_1]
151 ? S 0:08 /sbin/syslogd -m 0 -O /opt/var/log/messages -S -l 7
158 ? Ss 0:00 /opt/sbin/cron
162 ? S 0:03 [kjournald]
1826 ? S 0:12 upnp -D -L br0 -W vlan1
1953 ? Ss 0:00 /opt/sbin/nmbd -D
I waited a few more seconds and ran again and it has stopped.
ASUS:/tmp/local/root$ ps axf
PID TTY STAT TIME COMMAND
1 ? S 0:02 /sbin/init
2 ? S 0:00 [keventd]
3 ? SN 6:35 [ksoftirqd_CPU0]
4 ? S 0:12 [kswapd]
5 ? S 0:00 [bdflush]
6 ? S 0:00 [kupdated]
7 ? S 0:00 [mtdblockd]
63 ? R 0:02 telnetd
1935 pts/0 Ss 0:00 \_ -sh
1955 pts/0 R+ 0:00 \_ ps axf
68 ? S 0:10 httpd vlan1
74 ? S 0:32 dnsmasq
76 ? S 0:00 klogd
81 ? S 0:00 [khubd]
89 ? Ss 0:00 lpd
91 ? Ss 0:00 p9100d -f /dev/usb/lp0 0
95 ? Ss 0:00 waveservermain
97 ? Ss 0:00 rcamdmain
101 ? Ss 0:00 infosvr br0
102 ? Ss 0:11 watchdog
106 ? Ss 0:00 \_ ntp
127 ? S 0:00 udhcpc -i vlan1 -p /var/run/udhcpc0.pid -s /tmp/udhcpc
129 ? S 0:02 [usb-storage-0]
130 ? S 0:00 [scsi_eh_0]
133 ? S 0:00 [kjournald]
136 ? S 4:31 [usb-storage-1]
137 ? S 0:00 [scsi_eh_1]
151 ? S 0:08 /sbin/syslogd -m 0 -O /opt/var/log/messages -S -l 7
158 ? Ss 0:00 /opt/sbin/cron
162 ? S 0:03 [kjournald]
1826 ? S 0:12 upnp -D -L br0 -W vlan1
Thnx
wengi
Just tried that. Still nothing. log.nmbd and log.smbd show services started but that's it. No sign that SAMBA is actually running e.g. nothing to see in 'ps axf' or 'top' and ASUS not showing in MSHOME. Any further thought? Should I just start again?
Thanks. :)
Your xinetd is not running. Did you install it?
No xinetd -> no swat -> no config -> no samba.
wengi
wengi
I've reinstalled everything and xinetd is now running and using SWAT 'Status' page I can see smbd is 'running' and nmbd 'not running'.
log.nmbd shows
[2007/11/20 23:08:32, 0] source/nmbd/nmbd.c:main(795)
Netbios nameserver version 2.2.12 started.
Copyright Andrew Tridgell and the Samba Team 1994-2002
[2007/11/20 23:08:32, 0] source/lib/charset.c:load_client_codepage(213)
load_client_codepage: filename /opt/lib/codepages/codepage.850 does not exist.
[2007/11/20 23:08:32, 0] source/lib/util_unistr.c:load_unicode_map(617)
load_unicode_map: filename /opt/lib/codepages/unicode_map.850 does not exist.
[2007/11/20 23:08:32, 0] source/lib/util_unistr.c:load_unicode_map(617)
load_unicode_map: filename /opt/lib/codepages/unicode_map.ISO8859-1 does not exist.
[2007/11/20 23:08:36, 0] source/nmbd/nmbd_responserecordsdb.c:find_response_record(235)
find_response_record: response packet id 30649 received with no matching record.
When I try to browse with XP explorer I see 'ASUS' under MSHOME but when I try to browse I get '\\ASUS is not accessible' message.
Thanks :)
Hi,
the files of the codepages are missing. Very strange!
Here is the listing of my codepages:
Please recheck these files on your system.Code:[admin@blechbuechse /]$ ls /opt/lib/codepages/
total 3708
drwxr-xr-x 2 admin root 4096 Feb 25 2007 .
drwxr-xr-x 18 admin root 8192 Nov 5 08:37 ..
-rw-r--r-- 1 admin root 588 Feb 23 2007 codepage.1125
-rw-r--r-- 1 admin root 140 Feb 23 2007 codepage.1251
-rw-r--r-- 1 admin root 196 Feb 23 2007 codepage.437
-rw-r--r-- 1 admin root 148 Feb 23 2007 codepage.737
-rw-r--r-- 1 admin root 388 Feb 23 2007 codepage.775
-rw-r--r-- 1 admin root 132 Feb 23 2007 codepage.850
-rw-r--r-- 1 admin root 172 Feb 23 2007 codepage.852
-rw-r--r-- 1 admin root 132 Feb 23 2007 codepage.857
-rw-r--r-- 1 admin root 460 Feb 23 2007 codepage.861
-rw-r--r-- 1 admin root 588 Feb 23 2007 codepage.866
-rw-r--r-- 1 admin root 8 Feb 23 2007 codepage.932
-rw-r--r-- 1 admin root 8 Feb 23 2007 codepage.936
-rw-r--r-- 1 admin root 8 Feb 23 2007 codepage.949
-rw-r--r-- 1 admin root 8 Feb 23 2007 codepage.950
-rw-r--r-- 1 admin root 131614 Feb 23 2007 unicode_map.1125
-rw-r--r-- 1 admin root 131614 Feb 23 2007 unicode_map.1251
-rw-r--r-- 1 admin root 131614 Feb 23 2007 unicode_map.437
-rw-r--r-- 1 admin root 131614 Feb 23 2007 unicode_map.737
-rw-r--r-- 1 admin root 131614 Feb 23 2007 unicode_map.775
-rw-r--r-- 1 admin root 131614 Feb 23 2007 unicode_map.850
-rw-r--r-- 1 admin root 131614 Feb 23 2007 unicode_map.852
-rw-r--r-- 1 admin root 131614 Feb 23 2007 unicode_map.857
-rw-r--r-- 1 admin root 131614 Feb 23 2007 unicode_map.861
-rw-r--r-- 1 admin root 131614 Feb 23 2007 unicode_map.866
-rw-r--r-- 1 admin root 262174 Feb 23 2007 unicode_map.932
-rw-r--r-- 1 admin root 262174 Feb 23 2007 unicode_map.936
-rw-r--r-- 1 admin root 262174 Feb 23 2007 unicode_map.949
-rw-r--r-- 1 admin root 262174 Feb 23 2007 unicode_map.950
-rw-r--r-- 1 admin root 131614 Feb 23 2007 unicode_map.ISO8859-1
-rw-r--r-- 1 admin root 131614 Feb 23 2007 unicode_map.ISO8859-13
-rw-r--r-- 1 admin root 131614 Feb 23 2007 unicode_map.ISO8859-15
-rw-r--r-- 1 admin root 131614 Feb 23 2007 unicode_map.ISO8859-2
-rw-r--r-- 1 admin root 131614 Feb 23 2007 unicode_map.ISO8859-5
-rw-r--r-- 1 admin root 131614 Feb 23 2007 unicode_map.ISO8859-7
-rw-r--r-- 1 admin root 131614 Feb 23 2007 unicode_map.ISO8859-9
-rw-r--r-- 1 admin root 131614 Feb 23 2007 unicode_map.KOI8-R
-rw-r--r-- 1 admin root 131614 Feb 23 2007 unicode_map.KOI8-U
Also post the result ofwengiCode:cat /opt/etc/ipkg.conf
My /opt/lib/codepages/ is emtpy too.
Where can I find all this codepage files ? I use samba3.
wengi
I do not know what I did different but I cleared everything and started again. Samba2 and everything else is working. I will move onto Transmission soon once the samba drive is fully configured. Thank you for your advice and patience.
:D