Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revision Previous revision
Next revision
Previous revision
openwrt:troubleshooting [2015/08/20 05:14]
matthias stress some points in the new section
openwrt:troubleshooting [2017/12/16 11:22] (current)
comap89 Add: My USB stick died, how to restore my PirateBox ?
Line 2: Line 2:
 {{:​piratebox.hand.jpg?​600|}} {{:​piratebox.hand.jpg?​600|}}
  
-==== Technical FAQ ====+===== Technical FAQ =====
  
-=== I can'​t ​execute command ​from the Post Installation guide, what is wrong? ​=== +==== I can not execute command ​'​X' ​from the 'Post Installation' ​guide ==== 
-First of all double check if you typed in the command correctly. If so, your box is maybe not done with installation. The first clue is, that your command line looks like this ''​root@OpenWrt:​~#''​. The hostname is still **OpenWrt**,​ which is changed during a successful installation.+First of alldouble check if you typed in the command correctly. If so, your box is maybe not done with installation. The first clue is, that your command line looks like this ''​root@OpenWrt:​~#''​. The hostname is still **OpenWrt**,​ which is changed during a successful installation ​(to '​piratebox'​ with v1.0, something else from v1.1).
  
 \\ \\
  
-=== It seems my installation is still running, what went wrong? === +==== It seems my installation is still running, what went wrong? ​==== 
-If your box is online for more then 45 minutes, you may take a look into it to see what is going on. When you telnet into the box, like described in the installation guide, and execute the command ''​ps''​ , you have a long multiple line output. If you are able **to spot a line including "​opkg"​**,​ then everything is fine and it just take another while to finish. You can watch the installation using the following command ( using CTRL+C to exit the command)+If your box is online for more than 45 minutes, you may take a look into it in order to see what is going on. When you telnet into the box, like described in the installation guide, and execute the command ''​ps'',​ you have a long multiple line output. If you are able to **spot a line including "​opkg"​**,​ then everything is fine and it will just take another while to finish. You can watch the installation using the following command (use CTRL+C to exit this command):
  
   tail -f /​var/​log/​messages   tail -f /​var/​log/​messages
  
-If you **can'​t find opkg** ​linesmaybe your installation is stuck in detecting the USB stick. That can happen if the USB stick does not have a proper partition table, ​so in the system the device appears only as ''/​dev/​sda''​ instead of ''/​dev/​sda1''​. When you run ''​tail /​var/​log/​messages''​ you are able to spot a loong dotted line, which means "​Searching for USB". You can verify the assumption using this command ''​ls /​dev/​sd*'', ​if you see only ''/​dev/​sda''​ you might have an USB partition problem. The quickest solution is to change the PirateBox configuration to use the USB stick without the partition one indicate. To do so run the following commands:+If you **can'​t find opkg** ​lineperhaps that your installation is stuck in detecting the USB stick. That can happen if the USB stick does not have a proper partition table, ​the symptom is that in the system the device appears only as ''/​dev/​sda''​ instead of ''/​dev/​sda1''​. When you run ''​tail /​var/​log/​messages''​ you are able to spot a long dotted line, which means "​Searching for USB". You can verify the assumption ​by using the command ''​ls /dev/sd*''​. If you see ''/​dev/​sda'', ​''/​dev/​sda1''​ and ''/​dev/​sda2''​ you might need to repartition the USB stick in MSDOS mode, please follow the next section "HowTo format my USB stick correctly"​. If you see only ''/​dev/​sda''​ you might have an USB partition problem. The quickest solution is to change the PirateBox configuration to use the USB stick without the partition one indicate. To do sorun the following commands:
  
   sed -i '​s;​sda1;​sda;'​ /​etc/​ext.config ​   sed -i '​s;​sda1;​sda;'​ /​etc/​ext.config ​
   reboot & exit   reboot & exit
  
-After executing those line, the box will log you off and reboot. After the reboot is done, the installation tries to use /dev/sda only. See the tail commands ​above to watch at the installation progress. If you still have trouble, please post in the [[http://​forum.piratebox.cc|PirateBox Forum]] ​ and include the output of the technical summary below.+After executing those lines, the box will log you off and reboot. After the reboot is done, the installation tries to use ''​/dev/sda'' ​only. See the Tail command ​above to watch the installation progress. If you still have trouble, please post in the [[http://​forum.piratebox.cc|PirateBox Forum]] and include the output of the technical summary below.
  
 \\ \\
  
-=== When I connect to the PirateBox SSID, I can still access my network, but not the PirateBox. === +==== HowTo format my USB stick correctly? ==== 
-When you just finished your PirateBox installation,​ and you have your network cable still plugged into your PirateBox, you can'​t ​access the PirateBox. The PirateBox '​recognizes'​ that your home network is active and reroutes server IPs to your wifi-client, the result is not having access to the PirateBox and Internet is working.+PirateBox is a pretty bare metal tool. Newer operating systems, like Windows 10, are creating new partitions in [[https://​en.wikipedia.org/​wiki/​GUID_Partition_Table|GPT]] mode, but PirateBox needs an **[[https://​en.wikipedia.org/​wiki/​Master_boot_record|MBR]] mode** based partition format. The //first// Partition needs to be the **whole** partition and the partition type is required as **"​FAT32"​**. 
 +If you are running under a modern Windows, it is not easy to configure the USB stick in that way. It is recommended to use an additional tool named [[https://​rufus.akeo.ie/​|"​Rufus"​]],​ which can be obtained [[https://​rufus.akeo.ie/​|here]]. 
 + 
 + 
 +The options for formatting the USB Stick are:  
 +  * Partition scheme: MBR 
 +  * File system: FAT32 
 + 
 +** Attention:​** When executing this tool, this will remove all data on the USB stick! After formatting, please copy again the install folder to the USB stick then reboot your PirateBox. In some cases, it is needed to follow this tutorial in addition: [[openwrt:​reflash_with_autoflash|Reflash PirateBox with auto_flash function]]. 
 + 
 +\\ 
 + 
 +==== When I connect to the PirateBox SSID, I can still access my network, but not to the PirateBox. ​==== 
 +When you just finished your PirateBox installation,​ and you have your network cable still plugged into your PirateBox, you can not access the PirateBox. The PirateBox '​recognizes'​ that your home network is active and reroutes server IPs to your WIFI-client, the result is not having access to the PirateBox and Internet is working.
  
 \\  \\ 
  
-=== I can't access my PirateBox, is it bricked? === +==== I can't access my PirateBox, is it bricked? ​==== 
-In the most cases it isn'​t. ​Follow ​these steps to access [[openwrt:​failsafe|the failsafe mode]], then compare your output to [[openwrt:​tech_question_example_output|"​Example output for technical questions"​]]. Enter each of the commands on the linked page, note the differences,​ and ask for support on the [[http://​forum.piratebox.cc|PirateBox Forum]] or IRC channel(If your PirateBox responds at all to these commands, there'​s hope!)+In the most cases it isn'​t. ​The first step is to try to use a normal Ethernet connection (via wire) and a static IP address on the client side, which should be ''​192.168.1.2''​ (and maybe the subnet mask 255.255.255.0). That helps in some cases to get again access and do further steps. If the normal way does not help you, follow ​these steps to access [[openwrt:​failsafe|the failsafe mode]], then compare your output to [[openwrt:​tech_question_example_output|"​Example output for technical questions"​]]. Enter each of the commands on the linked page, note the differences,​ and ask for support on the [[http://​forum.piratebox.cc|PirateBox Forum]] or IRC channel (If your PirateBox responds at all to these commands, there'​s hope!)
  
 \\  \\ 
  
-=== But all network access failed, do I have to throw it away? ===+==== But all network access failed, do I have to throw it away? ====
 If you have tried both the above steps, and asked for help on the forum, and still have an unresponsive device, you may be able to recover your device (with a little surgery) via serial access: [[http://​ediy.com.my/​index.php/​blog/​item/​78-recover-bricked-tl-mr3020-wireless-n-router|Recover bricked TL-MR3020 Wireless N Router]], an example based on the MR3020. If you have tried both the above steps, and asked for help on the forum, and still have an unresponsive device, you may be able to recover your device (with a little surgery) via serial access: [[http://​ediy.com.my/​index.php/​blog/​item/​78-recover-bricked-tl-mr3020-wireless-n-router|Recover bricked TL-MR3020 Wireless N Router]], an example based on the MR3020.
  
 \\ \\
  
-=== Why has the USB stick be FAT32? What is with that limitations?​ ==== +==== Why has the USB stick be FAT32? What is with that limitations? ​===== 
-The most OperatingSystems ​can handle FAT32 filesystems,​ which makes it the best choice for the common user. Using FAT32 limits the filesize ​to a maximum of 4GB.  +The most of the operating systems ​can handle FAT32 filesystems,​ which makes it the best choice for the common user. However using FAT32 limits the files size to a maximum of 4GB.  
-Because the USB Stick is mounted with the filetype, you can'​t ​simply change the filesystem to one of your favor. Sorry, we plan this feature for the future.+Because the USB Stick is mounted with the filetype, you can not simply change the filesystem to one of your favor. Sorry, we plan this feature for the future.
  
 \\ \\
  
-=== I get error messages while running opkg update ====+==== I get error messages while running opkg update ​=====
 Depending on the error message several things can be wrong: Depending on the error message several things can be wrong:
  
Line 52: Line 65:
 \\ \\
  
-=== I think I have no internet connection on my PirateBox, what am I'​m ​doing wrong? ==== +==== I think I have no internet connection on my PirateBox, what am I doing wrong? ​===== 
-If you already installed PirateBox, please follow [[#​i_want_to_install_further_software_to_my_piratebox_but_it_seems_i_can_t_connect_to_the_internet_what_is_wrong|the hints about nodns]]. +If you already installed PirateBox, please follow [[#​i_want_to_install_further_software_to_my_piratebox_but_it_seems_i_can_t_connect_to_the_internet_what_is_wrong|the hints about 'nodns']]. 
-If not, it has to be figured outwhich configuration is wrong. ​can achieve that with running the following commands ​+If not, it has to be figured out which configuration is wrong. ​You can achieve that by running the following commands:
  
   ping -n 2 8.8.8.8   ping -n 2 8.8.8.8
   ping -n 2 google.com   ping -n 2 google.com
  
-If the first one failed, you have to double-check your gateway entry in ''/​etc/​config/​network''​. If the second command fails, something is wrong with the dns entry in the already mentioned configuration file. +If the first one failed, you have to double-check your gateway entry in ''/​etc/​config/​network''​. If the second command fails, something is wrong with the DNS entry in the already mentioned configuration file. 
  
 \\ \\
  
-=== I want to install further software to my PirateBox, but it seems I can't connect to the internet. What is wrong? ==== +==== I want to install further software to my PirateBox, but it seems I can't connect to the internet. What is wrong? ​===== 
-During the first days of PirateBox we had some problems with wrong entries in network configuration. To overcome this issue, PirateBox contains a fix, which gets activated during bootup. This fix redirects all request  ​on the box itself to the running PirateBox-Software. ​+During the first days of PirateBox we had some problems with wrong entries in the network configuration. To overcome this issue, PirateBox contains a fix, which gets activated during bootup. This fix redirects all requests ​on the box itself to the running PirateBox-Software. ​
 Assuming you did you configuration in ''/​etc/​config/​network''​ correctly, run Assuming you did you configuration in ''/​etc/​config/​network''​ correctly, run
  
   /​etc/​init.d/​piratebox nodns   /​etc/​init.d/​piratebox nodns
  
-This command disables that fix and ''​ping google.com''​ should point not to ''​192.168.1.1''​ anymore.+This command disables that fixand ''​ping google.com''​ should point not to ''​192.168.1.1''​ anymore.
  
 \\ \\
  
-=== I want to start from the beginning with flashing my device, but I don't have access to it anymore. What can I do? ==== +==== I want to start from the beginning with flashing my device, but I don't have access to it anymore. What can I do? ===== 
-You can try to reflash the device via [[openwrt:​failsafe|failsafe mode]] and [[openwrt:​reflash_with_usb|using and USB stick]] as data source. If you had installed an imagethat does not include the USB drivers, you may try advanced solution with [[openwrt:​reflash_wo_usb|copying the file over the network]].+You can try to reflash the device via [[openwrt:​failsafe|failsafe mode]] and [[openwrt:​reflash_with_usb|use an USB stick]] as data source. If you had installed an image that does not include the USB drivers, you may try advanced solution with [[openwrt:​reflash_wo_usb|copying the file over the network]].
  
 \\ \\
  
-=== I get error "No space left on device"​ while installing additional packages, what is wrong? ==== +==== I get error "No space left on device"​ while installing additional packages, what is wrong? ​===== 
-The "​disk"​-space of the small OpenWRT-Routers ​are usually very limited. The PirateBox package does a few tricks to overcome this issuewe  are installing ​the software into something called "​installation destination"​. If you want to install more software ​on your router, you have to run the ''​opkg''​ command with the paramter ​''​-d <​destination>''​.+The "​disk"​-space of the small OpenWRT ​routers ​are usually very limited. The PirateBox package does a few tricks to overcome this issuewe install ​the software into something called "​installation destination"​. If you want to install more softwares ​on your router, you have to run the ''​opkg''​ command with the parameter ​''​-d <​destination>''​.
  
 The following is valid for PirateBox 0.6 and below: The following is valid for PirateBox 0.6 and below:
Line 85: Line 98:
   opkg install -d piratebox <package name>   opkg install -d piratebox <package name>
  
-With PirateBox 1.0 we changed the destination name to a more common name+With PirateBox 1.0 we changed the destination name to a more common name:
  
   opkg install -d ext <package name>   opkg install -d ext <package name>
  
-If you still encounter this problem, you maybe already ​exhaustet ​your root diskspace (working directory for opkg) or the installation directory is really out of space (the last reason usually occur on trunk images running an "opkg upgrade"​).+If you still encounter this problem, you might have already ​exhaust ​your root diskspace (working directory for opkg) or the installation directory is really out of space (the last reason usually occur on trunk images running an "opkg upgrade"​).
  
 \\ \\
  
-=== How can I restore the original firmware? ==== +==== How can I restore the original firmware? ​===== 
-Restoring ​the original firmware to your OpenWRT device ​is maybe different for each device, please refer to [[http://​wiki.openwrt.org|to OpenWRT wiki for that]], i.e. [[openwrt>​toh/​tp-link/​tl-mr3020?#​restoring.original.firmware|Restoring for MR3020]]. Restoring back to the stock TP-Link causes the **most** bricks in our forum, so do a clever consideration or ask in the forum.+The process to restore ​the original firmware to your OpenWRT device ​can be different for each device, please refer to the [[http://​wiki.openwrt.org|OpenWRT wiki for that]], i.e. [[openwrt>​toh/​tp-link/​tl-mr3020?#​restoring.original.firmware|Restoring for MR3020]]. Restoring back to the stock TP-Link causes the **most** bricks in our forum, so do a clever consideration or ask in the forum.
  
  
 \\ \\
  
-=== It seems my Box does not accept the password ​when using ssh. === +==== When using SSH, it seems that my Box does not accept the password ​==== 
-When using ssh on a Mac or Linux system, do not forget **root@**192.168.1.1 . The ''​root@''​ is required, ​that ssh will try to login via the user "​root"​. If you miss that part out, the ssh command will use the user you are currently logged in. +When using SSH on a Mac or Linux system, do not forget **root@**192.168.1.1 . The ''​root@''​ is required, ​because ​ssh will try to login via the user "​root"​. If you miss that part out, the ssh command will use the user you are currently logged in. \\
 If it still does not work, try to use ''​telnet 192.168.1.1''​. If that work and you already used ''​passwd''​ to setup a password, something went wrong while flashing. Try to reflash the device with the openwrt*.bin file, or open up a forum post for clarification. If it still does not work, try to use ''​telnet 192.168.1.1''​. If that work and you already used ''​passwd''​ to setup a password, something went wrong while flashing. Try to reflash the device with the openwrt*.bin file, or open up a forum post for clarification.
  
 \\ \\
  
-=== I removed all the files from my USB stick and I'm not able to connect anymore. Is it bricked? === +==== I removed all the files from my USB stick and I'm not able to connect anymore. Is it bricked? ​==== 
-Don'​t ​panik. If you only removed the files on the USB Stick, the Box is using all the configuration,​ which was moved from the original system to the USB stick. This is the reasonwhy you can't connect easily anymorethe DHCP server is not working anymore. In the most situation, it could be the easiest solution to simply ​relash ​the device. For this copy your firmware image file and a copy of you unzipped install folder, then follow this [[openwrt:​reflash_with_usb|Reflash using an USB Stick]]-HowTo. **Please plugin the USB after you successfully logged in via failsafe mode**.+Don'​t ​panic. If you only removed the files on the USB Stick, the Box is using all the configuration,​ which was moved from the original system to the USB stick. This is the reason why you can't connect easily anymorethe DHCP server is not working anymore. ​\\ 
 +In the most situation, it could be the easiest solution to simply ​reflash ​the device
 +  * For **PirateBox 1.1** devices, you can use the [[openwrt:​reflash_with_autoflash|Reflash PirateBox with auto_flash function]]-HowTo.  
 +  * For //older// PirateBox: ​copy your firmware image file and a copy your unzipped install folder, then follow this [[openwrt:​reflash_with_usb|Reflash using an USB Stick]]-HowTo. **Please plugin the USB only after you successfully logged in via failsafe mode**
 + 
 +==== My USB stick died, how to restore my PirateBox ? ==== 
 +Use the instructions above.
  
 \\ \\
-==== Additional Support ====+===== Additional Support ​=====
 For general questions about the PirateBox project, please refer to the **[[::​faq|FAQ page]]**. For general questions about the PirateBox project, please refer to the **[[::​faq|FAQ page]]**.
  
Line 128: Line 147:
   * Follow up with a brief note on the solution if you find one   * Follow up with a brief note on the solution if you find one
  
-==== Technical summary ====+===== Technical summary ​=====
  
 If asked, please post the output of the following commands: If asked, please post the output of the following commands:
Line 150: Line 169:
    ls /dev/sd*    ls /dev/sd*
    ps    ps
-   cat /​mnt/​usb/​install.log ​+   tail -n 200 /​mnt/​usb/​install.log ​
  
-You can find the an [[openwrt:​tech_question_example_output|example output]] ​for comparison ​to get an idea what is maybe wrong.+For comparison, you can read this [[openwrt:​tech_question_example_output|example output]], in order to get an idea about what might be wrong.