Author |
Message |
Kamilion
Kai Beginner
Joined: 11 Dec 2004
Posts: 2
Location: USA - Nevada
|
Posted:
Sat Dec 11, 2004 4:48 pm |
|
Getting KaiEngine running on a Linksys WRT54G (With Sveasoft Alchemy/Satori or OpenWRT/HyperWRT firmware)
Please feel free to mirror the zip file this has linked, but please ask me before modifying.
I don't have the time to answer every question you may have personally via email...
But you might try asking me via a forum PM or looking in my forum profile or in the IRC channel on EFnet #xlink
If you act like an asshat, I'll treat you like one. If you're kind and courteous, I just might help you.
-------------------------------------------------------------------------
Before you Begin
-------------------------------------------------------------------------
You will need your Linksys flashed to a sveasoft image.
http://slashdot.org/~TheIndividual/journal/
http://slashdot.org/~TheIndividual/journal/90086 (For Mirrors)
A direct download link:
http://users.atw.hu/wrt54g/WRT54G_Wolf_W42_Alchemy_6rc1_by_TheIndividual.zip
I cannot personally support this software. Use at your own risk.
If you flash Alchemy on your router:
MAKE SURE YOU SET BOOT WAIT ON AND ALWAYS FLASH FROM AN ETHERNET CABLE.
You can do this by logging into your router, going to Management, and looking for Boot Wait.
Set it to ON and click Save Settings at the bottom of the page.
(This only applies if you're using Satori or Alchemy already.)
-------------------------------------------------------------------------
IF YOU JUST PURCHASED YOUR WRT54G/GS OR HAVE NOT FLASHED IT, DO THIS FIRST!
-------------------------------------------------------------------------
If you have a Linksys firmware version newer than 1.42.2, you can set boot_wait on directly.
In your web browser, go to the Ping.asp page on your router.
One by one, copy and paste the following commands in to the address field and run a ping:
;cp${IFS}*/*/nvram${IFS}/tmp/n
;*/n${IFS}set${IFS}boot_wait=on
;*/n${IFS}commit
3. To confirm that these commands have successfully enabled boot_wait, 'ping' this command:
;*/n${IFS}show>tmp/ping.log
This should show several pages worth of variables. Scroll down until you find boot_wait and make sure it's set to 1.
THIS WILL KEEP YOUR WRT FROM TURNING INTO A BRICK. DO IT.
-------------------------------------------------------------------------
Note: If you're using telnet, please stop. Use SSH instead. It's easy to set up and a lot more secure.
If you need a SSH/Telnet client, use Putty.
http://www.chiark.greenend.org.uk/~sgtatham/putty/ (Main site)
http://www.tartarus.org/~simon/putty-snapshots/x86/putty.exe (Direct Download of latest snapshot)
Links to software used:
http://www.aprelium.com/abyssws/ (For local PC hosting of kaid -- Hope your bandwidth bill goes down, zbit.pl!)
http://www.chiark.greenend.org.uk/~sgtatham/putty/ (For SSH/Telnet connections)
[url]http://www.teamxlink.co.uk/ [/url] (Kai and KaiEngine. You should already know this by now.)
You will need to download kaid from here:
http://www.zbit.pt/kai/mips/fs/usr/bin/kaid
Please only download it once per version to save ^S^'s bandwidth.
^S^ says @ http://www.teamxlink.co.uk/forum/viewtopic.php?p=33603#33603
"I've had 7GB traffic just for kaibinary.bin in less than 24h...
figures not far from that for mips/fs/.../kaid ... You do the math for every reboot, the 1MB download..."
-------------------------------------------------------------------------
Local PC Webserver Setup
-------------------------------------------------------------------------
Install abyss X1 webserver.
If XPSP2 asks to unblock, do so.
Abyss will start up, and tell you a configuration has been created and automatically open your web browser.
Enter any username you wish into Administrator Login, and the password you choose twice.
You'll need this to make any sort of config changes at http://127.0.0.1:9999/ (default)
It will then ask you to login using the username and password you have just created.
Click on Server Configuration.
You should see (if you did not change anything in the installer, and are using an english version of windows):
Server root: C:\Program Files\Abyss Web Server\
Documents Path: htdocs
Port: 8000
Note: PORT: may be different. If it is, make a note of it.
You'll need to change the script coming later (change :8000 to :<Whatever Port: says> )
You can close your webbrowser now, If you have changed the Port: you must click OK before you close it.
If you didn't change anything, just close it.
By default, Abyss will install to C:\Program Files\Abyss Web Server\
Within this directory, there is a folder named htdocs.
This is the root directory for the server, where all the files you are hosting go.
Place kaid and kaid.conf there now.
-------------------------------------------------------------------------
Configuration editing
-------------------------------------------------------------------------
I have included a configuration editor named confedit.exe and a default kaid.conf with more linksys information.
You may drag kaid.conf onto Confedit.exe to open it automatically.
Edit your config now to add your console's MAC address and if nessicary, SniffDevice.
The WRT54G 2.0 & WRT54GS use vlan0 for the 4 port switch and vlan1 for the WAN port
Also, the wireless on the WRT54G 2.0/GS is eth1. It is not bridged with the internal lan
The WRT54G 1.0 and 1.1 use br0 (bridge 0) for all switch ports (eth0) and wireless (eth2).
Wan is on eth1. Wireless on eth2. Switch on eth0. eth0 and eth2 are bridged on br0.
(Check bottom of WRT54G/GS for Version ID)
For Linksys WRT 1.0 & 1.1 use br0 -- for 2.0 use vlan0 for ethernet, eth1 for wireless
If your WRT says "WRT54G" and "1.0" or no version, and has about 20 lights on the front, with one marked "DIAG" you have a 1.0.
SniffDevice = br0
If your WRT says "WRT54G" and "1.1" and has 8 lights and NO DIAG, you have a 1.1
SniffDevice = br0
If your WRT says "WRT54G" and "2.0" or "2.2" or "WRT54GS" and has 8 lights, you have a 2.x.
For Wired Ethernet (A cable going to your console) set this:
SniffDevice = vlan0
For Wireless (Nintendo DS/PSP/Wireless Extender for TV-based consoles) set this:
SniffDevice = eth1
Now, you must set your MAC address(es)
Look for something like the following.
ConsoleMacs = 00:00:00:00:00:00;
Replace the 00:00:00:00:00:00 with your console's MAC address.
If it is using DHCP, you may possibly find this using 'dumpleases' over telnet/ssh/webconfig diagnostics.
For the PSP, you can find it's MAC address in the System Settings.
http://img6.exs.cx/img6/1962/GA000080049.jpg
MAKE SURE THERE IS A ; AT THE END OF THE LINE.
IF you have more than one console, you may seperate them using a ; but make sure there's one at the end. Here's an example.
ConsoleMacs = 00:00:00:00:00:00;88:00:00:00:00:01;
For two consoles.
ConsoleMacs = 00:00:00:00:00:00;88:00:00:00:00:01;99:00:00:00:00:02;
For three consoles.
And so on.
-------------------------------------------------------------------------
Running the script
-------------------------------------------------------------------------
Now that you have a kaid.conf, save it to the htdocs folder.
If you look in your System Tray, you'll see a little green circle if abyss is running, and an X through it if it is not.
If it's running, now we try to start up kaid on the WRT.
Here is a working script to run from telnet/sshd/Webconfig diagnostics to start up kaid.
It Works For Me, Your Milage May Vary.
You may need to change the IP addresses to your PC's IP.
You can find this through your Linksys's Status / DHCP leases page or run 'dumpleases' from telnet/ssh
wget http://192.168.0.1:8000/kaid.conf -O /tmp/kaid.conf
wget http://192.168.0.1:8000/kaid -O /tmp/kaid
cd /tmp && chmod +x /tmp/kaid && /tmp/kaid &
The second line may take up to a minute to transfer kaid.
Your PC may have a different IP address, or Abyss may have a different port than my configuration.
If so, change the IP and port in the example script above.
For example, if the PC you are running Abyss on is 192.168.1.100 and Abyss is on port 4762,
wget http://192.168.1.100:4762/kaid.conf -O /tmp/kaid.conf
The syntax is thus:
http://IPADDRESS:PORT/FILE
-------------------------------------------------------------------------
Status checking and Shutting down kaid
-------------------------------------------------------------------------
You may check that kaid is running using 'ps' (telnet/ssh/webconfig diagnostics) or 'top' (telnet/ssh)
At this point, you may use your kai client from Windows/Linux/OSX/Xbox and everything should work.
To shut down kaid, use this command:
killall -9 kaid
-------------------------------------------------------------------------
Outro and Credits
-------------------------------------------------------------------------
Thanks to TheDaddy & all devs for Xlink Kai!
Thanks to ^S^ for porting/compiling kaid / KaiEngine for WRT class routers!
Thanks to Puma81 #xlink/EFNET for beta testing!
And most of all, thanks to Airi for love and support!
Hope this helps everyone out!
Here are the files.
Primary Mirror (Thanks to TaskMaster):
http://www.jprroofing.com/kaid/kaiEngine-For-WRT54G.rar
Secondary Mirror (Thanks to graffiti.net)
http://home.graffiti.net/djkamilion:graffiti.net/kaiEngine-For-WRT54G.rar
It will run out of bandwidth pretty fast, so I would appreciate it if someone would mirror it. It's only 360KB.
--Kamilion |
Last edited by Kamilion on Sat Dec 11, 2004 10:17 pm; edited 1 time in total |
|
|
|
Kamilion
Kai Beginner
Joined: 11 Dec 2004
Posts: 2
Location: USA - Nevada
|
Posted:
Sat Dec 11, 2004 5:43 pm |
|
Also -- you may close Abyss once the two wgets finish running.
Run Abyss if you reboot your router and need to run the script again.
Just thought I'd mention that. Cheers! |
Last edited by Kamilion on Mon Dec 13, 2004 1:50 am; edited 1 time in total |
|
|
|
TaskMaster
Kai Regular
Joined: 21 May 2004
Posts: 85
Location: USA - Massachusetts
|
Posted:
Sun Dec 12, 2004 2:29 am |
|
I setup my files to be retrieved from an external webserver but the problem was the script was running before the router had finished connecting to my ISP (I have a PPPoE DSL account). I modified the script a bit and it did the trick. The startup script I use is below is just slightly modified in that I added an initial delay and called out the kaid.conf file:
sleep 30
wget http://<webserver address>/kaid.conf -O /tmp/kaid.conf
wget http://<webserver address>/kaid -O /tmp/kaid
cd /tmp && chmod +x /tmp/kaid && /tmp/kaid -c kaid.conf & |
Last edited by TaskMaster on Sun Dec 12, 2004 11:42 am; edited 1 time in total |
|
|
|
xlinkxbox100
Kai Beginner
Joined: 02 Dec 2004
Posts: 12
Location: USA - Connecticut
|
Posted:
Sun Dec 12, 2004 5:27 am |
|
just wanted to say a big THANKS to the xlink team, and for posting this sticky.
Quote: |
If your WRT says "WRT54G" and "2.0" or "2.2" or "WRT54GS" and has 8 lights, you have a 2.x.
For Wired Ethernet (A cable going to your console) set this:
SniffDevice = vlan0 |
that fixed my problem where I could logon to xlink network with xbmc, but once in system link I wouldn't see any games. Since I have a version 2 wrt54g, I needed to change the sniff device to that.
Now I'm off to game.
Thanks again |
|
|
|
|
traxxas
Kai Beginner
Joined: 30 Nov 2004
Posts: 6
Location: USA - Florida
|
Posted:
Sun Dec 12, 2004 4:19 pm |
|
OK...i believe i need to change my sniff ....i am using a wireless G setup for the xbox. Now i am no dummy but i have never used telnet before. I have read this thread and a read me file with the same info. But i need help with the telnet part.
I have flashed my WRT54G 2.0 with Kiastation.bin
i have edited the kai.conf to my needs
i have abyss running fine
i have downloaded putty.exe (this is where i have the problem)
Could someone find it in their heart to help me with a putty step-by-step???
wouldnt it be easer to edit the kaistation.bin somehow and just reflash it if you want to change the sniff? |
|
|
|
|
TaskMaster
Kai Regular
Joined: 21 May 2004
Posts: 85
Location: USA - Massachusetts
|
Posted:
Sun Dec 12, 2004 5:03 pm |
|
Just to make sure you are not confused, this thread is discussing loading the KAID binary and KAID.CONF files to the RAM of a WRT54G(S) while running an alternate bios on the router (Sveasoft, mainly). This does not have anything to do with loading the kaistation.bin and running with that bios. |
|
|
|
|
traxxas
Kai Beginner
Joined: 30 Nov 2004
Posts: 6
Location: USA - Florida
|
Posted:
Sun Dec 12, 2004 8:39 pm |
|
understood... i have also loaded sevasoft bin. but i can not telnet it. When it asks for the password....i cant type anything in. Thne the login in fails. Any ideas? |
|
|
|
|
Puma81
Team XLink Moderator
Joined: 21 May 2004
Posts: 278
|
Posted:
Sun Dec 12, 2004 9:11 pm |
|
on the seavsoft fimwares you enable the telnet fuction in the web setup page. Go to Administration and on that page enable Telnet. once its enabled go to Start -> Run, and type in Telnet 192.168.0.1 . the log in is root and the password is what you use to log into the web setup page. |
|
|
|
|
imagenius
Kai Beginner
Joined: 14 Nov 2004
Posts: 9
Location: USA - Florida
|
Posted:
Sun Dec 12, 2004 10:19 pm |
|
TaskMaster wrote: |
I setup my files to be retrieved from an external webserver but the problem was the script was running before the router had finished connecting to my ISP (I have a PPPoE DSL account). I modified the script a bit and it did the trick. The startup script I use is below is just slightly modified in that I added an initial delay and called out the kaid.conf file:
sleep 30
wget http://<webserver address>/kaid.conf -O /tmp/kaid.conf
wget http://<webserver address>/kaid -O /tmp/kaid
cd /tmp && chmod +x /tmp/kaid && /tmp/kaid -c kaid.conf & |
I can run the commands through telnet but what do I name and where do I put the script on the router to make this happen right when it turns on like you have it? Sorry if this is an ultranoob question. |
|
|
|
|
TaskMaster
Kai Regular
Joined: 21 May 2004
Posts: 85
Location: USA - Massachusetts
|
Posted:
Sun Dec 12, 2004 10:39 pm |
|
You go to your router's administration page in a web browser and login (by default this is usually at 192.168.1.1). Then go to ADMINISTRATION > DIAGNOSTICS and then click the RUN button. Type or paste your script into the box labelled Commands, but don't hit the CMD button - instead hit the button at the bottom labelled Save Startup. This will make the script load each time the router restarts. If you later want to clear or change the script, just repeat the procedure and enter either your complete new script or just leave the Commands field blank and hit the Save Startup button if you want to eliminate any startup script. Does that clear it up? |
|
|
|
|
imagenius
Kai Beginner
Joined: 14 Nov 2004
Posts: 9
Location: USA - Florida
|
Posted:
Sun Dec 12, 2004 10:47 pm |
|
Thanks just saw that in the other thread Now the only problem I have is that it says:
CONFIG: Downloading settings from http://www.teamxlink.co.uk/connector/clientgetconfig.php...
CONFIG: Error getting Orb List: 'Specified Host Name is Invalid
'.
Any ideas why this is happening? thanks in advance |
|
|
|
|
TaskMaster
Kai Regular
Joined: 21 May 2004
Posts: 85
Location: USA - Massachusetts
|
Posted:
Sun Dec 12, 2004 11:02 pm |
|
|
|
|
imagenius
Kai Beginner
Joined: 14 Nov 2004
Posts: 9
Location: USA - Florida
|
Posted:
Sun Dec 12, 2004 11:08 pm |
|
Thats the wierd part. I can view it from my web browser but when I try to ping www.teamxlink.co.uk from the router or my comp it wont ping. And when I ping it from my router it says unknown host. |
|
|
|
|
TaskMaster
Kai Regular
Joined: 21 May 2004
Posts: 85
Location: USA - Massachusetts
|
Posted:
Sun Dec 12, 2004 11:45 pm |
|
I can't ping it either. I am betting they have ICMP disabled so you cannot ping that address, however the 'unknown host' would have me concerned. When I ping from the router the pings timeout, but the host is still resolved. Try running a traceroute. from the PC use
tracert www.teamxlink.co.uk
From the router use
traceroute www.teamxlink.co.uk
And see if the host is resolved. Note the traceroute will not complete all the way (at least for me it only made it to 209.49.35.18). This should confirm whether or not the host is being resolved by your router. If the address is not being resolved by the router I would go to my router setup and add an alternate DNS to backup the one your ISP is using. |
|
|
|
|
imagenius
Kai Beginner
Joined: 14 Nov 2004
Posts: 9
Location: USA - Florida
|
Posted:
Mon Dec 13, 2004 2:26 am |
|
Thanks for the help taskmaster it turned out that the problem was that I have two WRT54G routers in WDS mode and I was trying to run kaid on the one that isnt directly connected to the internet. The one that is connected to the net is able to resolve the host. So now im just going to put it on the internet connected one. Any ideas what settings I may need to change to get it to work on the router connected directly to my xbox? |
|
|
|
|
imagenius
Kai Beginner
Joined: 14 Nov 2004
Posts: 9
Location: USA - Florida
|
Posted:
Mon Dec 13, 2004 2:35 am |
|
Turned out all I needed to do was set the local dns setting on the router connected to my xbox to my cable isps dns server ip and it works fine! Thanks for the help. |
|
|
|
|
yazoo32
Kai Beginner
Joined: 02 Dec 2004
Posts: 12
Location: United Kingdom
|
Posted:
Mon Dec 13, 2004 1:30 pm |
|
I get a 'Network is unreachable' when I try to ping from the diagnostics page.
Why is that? |
|
|
|
|
TaskMaster
Kai Regular
Joined: 21 May 2004
Posts: 85
Location: USA - Massachusetts
|
Posted:
Mon Dec 13, 2004 3:58 pm |
|
@ imagenius - Good to hear, I hope I was some help.
@ yazoo32 - What do you get when you ping from your PC? Is the router you are pinging from your gateway and is it connected to your ISP Modem? Please describe how you are connected/what hardware you are using. Thanks. |
|
|
|
|
yazoo32
Kai Beginner
Joined: 02 Dec 2004
Posts: 12
Location: United Kingdom
|
Posted:
Mon Dec 13, 2004 5:07 pm |
|
|
|
|
Sykobabble
Kai Beginner
Joined: 09 Oct 2004
Posts: 32
Location: United Kingdom
|
Posted:
Mon Dec 13, 2004 8:43 pm |
|
Everything seems to go OK but I get the follow Unknow directive Error
Code: |
~ # wget http://192.168.1.2/kaid.conf -O /tmp/kaid.conf
Connecting to 192.168.1.2[192.168.1.2]:80
kaid.conf 100% |*****************************| 3388 00:00 ETA
~ # wget http://192.168.1.2/kaid -O /tmp/kaid
Connecting to 192.168.1.2[192.168.1.2]:80
kaid 100% |*****************************| 1197 KB 00:00 ETA
~ # cd /tmp && chmod +x /tmp/kaid && /tmp/kaid &
~ # KAI: Reading settings from kaid.conf
'.NFIG: Config: Unknow directive '
'.NFIG: Config: Unknow directive '
'.NFIG: Config: Unknow directive '
'.NFIG: Config: Unknow directive '
'.NFIG: Config: Unknow directive '
'.NFIG: Config: Unknow directive '
'.NFIG: Config: Unknow directive '
'.NFIG: Config: Unknow directive '
'.NFIG: Config: Unknow directive '
CONFIG: Downloading settings from http://www.teamxlink.co.uk/connector/clientget
...fig.php
CONFIG: 4 orbital(s) available...
KAI: Kai for KaiStation now starting...
KAI: Listening for UI's on :34522
KAI: Added 2 device(s) to engine cache.
PKTSNIFF: Setting up packet sniffer...
'. pcap error was 'ioctl: No such device'.
Try using 'br0' as SnifferDevice |
Can anyone help?
Thanks
Sykobabble |
|
|
|
|
|