New Guy Needs Help Please

Posted by nc6262 
This forum is currently read only. You can not log in or make any changes. This is a temporary situation.
Now, this forum is in read-only mode. You find details Details hereContinue on /r/PirateBox
New Guy Needs Help Please
July 19, 2013 03:13PM
Hello.
Need help device is 3020 installed busy box v1.19.4 OpenWrt can logon as root ( root@192.168.1.1 ) when I go to at the # vi /ect/config/network and hit enter. I see no config listed. only ~ no text and the last line is - /ect/config/network 1/1 100%

Thanks
Z
I have a similar problem
July 20, 2013 05:27PM
I am completing the DIY-openWrt instructions at [daviddarts.com]

I have everything done through step 9 but at step ten when i command vi /etc/config/network my file does not look like it is supposed to. This is what I get:

root@OpenWrt:~# vi /etc/config/network


config interface 'loopback'
option ifname 'lo'
option proto 'static'
option ipaddr '127.0.0.1'
option netmask '255.0.0.0'

config interface 'lan'
option ifname 'eth0'
option type 'bridge'
option proto 'static'
option ipaddr '192.168.1.1'
option netmask '255.255.255.0'

~
~
~
~
~
~
~
~
~
- /etc/config/network 1/14 7%


So I am missing some lines at the bottom and option ipaddr '192.168.2.111' is 192.168.1.1. I dont know what to do from here.
Re: I have a similar problem
July 21, 2013 06:07AM
I'm pretty much stuck there too. Except now I think I bricked my router because I closed the terminal and shutdown my computer while I was in the middle of editing the file because I was in a rush to go to work and when I came back I couldn't get to the OpenWrt page in the terminal as easily. As soon as I learn how to create my piratebox I'm going to create a tutorial and post it on YT.
Re: New Guy Needs Help Please
July 21, 2013 09:54AM
@nc6262 you have a typo , it should be /etc/config/network not /ect/config/network
@z I think it's correct already, just proceed to edit it
@The4aner have you tried enter in failsafe mode?
Z
Re: New Guy Needs Help Please
July 21, 2013 02:02PM
I see, I edited the file to match the above and proceeded but it did not work. I think the problem is that my home gateway ip is different as it suggests may be the case. Since this is the first time i have done anything like this I think I screwed up the edit though. I am on a macbook pro, looked under system preferences for the IP and found the airport section where it said router : 192.168.1.1 but I think I should have been looking at the section IPv4 which is 192.168.1.2?

So I reedited the file to appear as
config interface 'lan'
option ifname 'eth0'
option type 'bridge'
option proto 'static'
option ipaddr '192.168.2.111'
option netmask '255.255.255.0'
option gateway '192.168.1.1'
list dns '192.168.1.1'
list dns '8.8.8.8'

but unfortunately I think I may have guessed wrong and should have put 192.168.1.2 instead because now I cannot log back in to the router to change this file. Any suggestions as to how to get back to the right place? previously I had used ssh root@192.168.1.1 but now I get this...
ssh: connect to host 192.168.1.1 port 22: Network is unreachable
Re: New Guy Needs Help Please
July 21, 2013 04:39PM
@z : I think you should use ssh root@192.168.2.111



Edited 1 time(s). Last edit at 07/21/2013 04:39PM by johanrusli.
Z
Re: New Guy Needs Help Please
July 21, 2013 06:09PM
with MR3020 connected to home router and laptop wireless on:
ssh root@192.168.2.111
ssh: connect to host 192.168.2.111 port 22: Operation timed out

This does actually let me connect when mr3020 is ethernet connected and wireless off. So I was able to change the gateway IP to the right number but this still gives the same timed out message when connecting wirelessly.

any thoughts? It seems that since i can log in when it is connecting directly that somehow the settings are wrong since it cant find it when connecting wirelessly.



Edited 1 time(s). Last edit at 07/21/2013 06:29PM by Z.
Re: New Guy Needs Help Please
July 25, 2013 11:05AM
somehow your configuration is messed up.

On the one side you are using 192.168.1.x addresses on the other side 192.168.2.x - so what is correct? What IP range is your home network?


What IP does your client gets assigned when you are logged in your homenetwork?
Z
Re: New Guy Needs Help Please
July 25, 2013 06:34PM
When I have the MR3020 attached to my home router by ethernet and then I wirelessly connect to the labtop this is what my network settings show [dl.dropboxusercontent.com]

the IPv4 address though seems to change different times I check. it has been 192.168.1.3, 192.168.1.2 as well.

when I turn off the wireless and ethernet directly to the mr3020 my network looks like this [dl.dropboxusercontent.com]

logging into the router and issuing vi /etc/config/network yeilds

config interface 'loopback'
option ifname 'lo'
option proto 'static'
option ipaddr '127.0.0.1'
option netmask '255.0.0.0'

config interface 'lan'
option ifname 'eth0'
option type 'bridge'
option proto 'static'
option ipaddr '192.168.2.111'
option netmask '255.255.255.0'
option gateway '192.168.1.2'
list dns '192.168.1.2'
list dns '8.8.8.8'
~
~
~
~
~
~
~
- /etc/config/network 1/16 6%
Re: New Guy Needs Help Please
July 25, 2013 08:03PM
Z

In your case (based on the pics you linked),
192.168.1.1 is your home router (option gateway ! )
192.168.1.x any device connected to your home network

192.168.2.111 is the address of the PirateBox (hence you have to ssh to this address for login)
192.168.2.x any address the PirateBox gives in the network
___________________________________________________

It is advised to change the address of your PB to 192.168.1.x (where X is not 1, else it would collide with your home router!). Otherwise the IP should be changed to 192.168.2.111 in piratebox.conf as well. This is complicated, so lets change the address of your PB to 192.168.1.254 for instance.

With the current setup you need to login to your PirateBox via
ssh root@192.168.2.111
Now to log in to your box :
Connect your computer to the PB via ethernet cable. Enter above command

(If you can't manage to get a login, try setting a fixed IP to your etherenet connection for the time being. But as you wrote earlier you can get a login, so this shouldn't be a problem)

In
/etc/config/network
change the line
option ipaddr '192.168.1.254'

Also, to get internet access to your PB when it is connected to your home router change in
option gateway '192.168.1.1'

Note: after rebooting the router it's IP address will be 192.168.1.254 so from this point on you will need this address to ssh during login.

Also, you should be able to connect to your piratebox via wifi as well.
Do you see a "PirateBox - Share Freely" wifi network?
Can you make a successful connection to it?



Edited 1 time(s). Last edit at 07/25/2013 08:23PM by Nargren.
Z
Re: New Guy Needs Help Please
July 26, 2013 01:03PM
That worked perfectly, thanks so much. I am now up and running!
Re: New Guy Needs Help Please
July 28, 2013 06:57AM
I don't quite understand how to get into failsafe mode. I have however managed to get to the OpenWrt mainscreen on the terminal, how I did it? I have no clue but the good thing is I know I can still access it. I'm gonna give it one last try if that doesn't work than I'm just gonna have to buy another router and choose a day off to work on the PBox all day. I'll probably sell the bricked router for bitcoin.
Re: New Guy Needs Help Please
July 28, 2013 09:46AM
If you could access the terminal, you don't need to failsafe.
Re: New Guy Needs Help Please
August 01, 2013 01:01AM
Well, due to the fact that I bricked my router and haven't been able to install the PirateBox on it I ordered another one and it arrived today! smiling bouncing smiley If anyone here has succesffully created their PirateBox and would be willing to help me make mine let me know via PM. I will most likely sell the bricked router for BTC or something. I can still access the OpenWrt settings in the terminal using failsafe mode but I just haven't been able to complete the installation.