Site Tools


remote_upgrade_poc

Differences

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

Link to this comparison view

Both sides previous revisionPrevious revision
Next revision
Previous revision
Next revisionBoth sides next revision
remote_upgrade_poc [2023/06/27 00:01] – [Remote Upgrade types] -move body text below into bulleted sections. hogwildremote_upgrade_poc [2023/07/01 01:28] – [Preservation of Parameters and Restore Process]-formatting hogwild
Line 40: Line 40:
   - A VPN server is configured, enabled and working.   - A VPN server is configured, enabled and working.
   - Dropbear/SSH access is possible.   - Dropbear/SSH access is possible.
-  - The internal network has an Ethernet LAN client that accessible via Teamviewer, once Internet connectivity \\ is available after minimal upgrade & reconfiguration. This will be used to complete other major reconfiguration.+  - The internal network has an Ethernet LAN client that accessible via Teamviewer, \\ once Internet connectivity is available after minimal upgrade & reconfiguration. \\ This will be used to complete other major reconfiguration.
  
  
Line 116: Line 116:
  
 There are several types of remote upgrades. They can be summarized in order of risk, as follows: There are several types of remote upgrades. They can be summarized in order of risk, as follows:
 + \\ 
 + \\ 
 +  * Dirty upgrade - overwrites the firmware and retains current NVRAM settings. This is probably \\ the safest method. It will function similar to an upgrade using the router's web interface. \\ \\ 
 +  * Clean upgrade - overwrites firmware and erases NVRAM settings, (restoring the default ones). \\ This will restore default settings, IP address and logon credentials. This is generally not a good option \\ when doing a remote upgrade. However, it can speed up the upgrade process if you're beside the router. \\ \\ 
 +  * Advanced upgrade - overwrites firmware, saves selected NVRAM configuration, erases NVRAM \\ and  restores saved settings via USB automount. This should be used only in unusual cases. \\ Such cases include sensitive remote installations, large installations, or anything that would justify \\ automating that level of complexity.
  
-  * Dirty upgrade - overwrites the firmware and retains current NVRAM settings. \\ This is probably the safest method. It will function similar to an upgrade using the router's web interface. + \\ 
-  * Clean upgrade - overwrites the firmware and erases NVRAM settings, (restoring the default ones). \\ This will restore the default settings, IP address and logon credentials. This is generally not a good option when doing a remote upgrade. However, it can useful for speeding up the upgrade process if you are physically beside the router. +
-  * Advanced upgrade - overwrites firmware, saves selected NVRAM configuration, erases NVRAM and  \\ restores saved settings via USB automount. should be used only in unusual cases. Such cases include sensitive remote installations, large installations, or anything that would justify automating that level of complexity. +
- +
-A dirty upgrade is probably the least risky method. It will function similar to an upgrade using the router's web interface. +
- +
-A clean upgrade will restore the default settings, IP address and logon credentials. This is generally not a good option when doing a remote upgrade. However, it can useful for speeding up the upgrade process if you are physically beside the hardware device. +
- +
-Advanced upgrades should be used only in unusual cases. Such cases include sensitive remote installations, large installations, or anything that would justify automating that level of complexity. +
- +
 ==== Dirty Upgrade ==== ==== Dirty Upgrade ====
  
Line 163: Line 158:
  
   - Evaluate the use of external files for certificates.   - Evaluate the use of external files for certificates.
-  - Evaluate the use of an external file for the list of parameters which need to be preserved.+  - Evaluate the use of an external file for the list of parameters to be preserved.
   - Replace the: `....` notation for subshell with FreshTomato's default syntax of:  "$(....)".   - Replace the: `....` notation for subshell with FreshTomato's default syntax of:  "$(....)".
-  - Consider handling EOL of files you reference internally. There are many sed examples on how to achieve this and force LR.+  - Consider handling EOL of files you reference internally. There are many sed examples \\ on how to do this and force LR.
   - Consider defining the USB path as a variable at the beginning of your script.   - Consider defining the USB path as a variable at the beginning of your script.
-  - Remember: some devices might have multiple USB drives plugged/multiple partitions. A "scan" of their content might help.+  - Remember: some devices might have multiple USB drives plugged/multiple partitions. \\ A "scan" of their content might help.
  
  \\  \\
Line 178: Line 173:
 The Main Preserve Script, with a list of parameters to save, creates the Restore script with actual parameter values. The Main Preserve Script, with a list of parameters to save, creates the Restore script with actual parameter values.
  
-**Caution: Unexpected side effects can occur if any parameter value contains the single quote (') character. ** +**Caution: Unexpected side effects can occur if any parameter value contains the single quote (') character. Consider replacing single quotes with double quotes (") whenever possible.**
- +
-**Consider replacing single quotes with double quote (") whenever possible.**+
  
  \\  \\
  
-After every upgrade, you should review the FreshTomato Changelog and code commits to help you decide whether further configuration adjustments will be needed. Such adjustments could be caused by:+After every upgrade, you should review the FreshTomato changelog and code commits to help you decide whether further configuration adjustments will be needed. Such adjustments could be caused by:
  
   - Bug fixes   - Bug fixes
Line 190: Line 183:
   - New features   - New features
   - Explicit recommendations from the developers   - Explicit recommendations from the developers
 +
  \\  \\
  
Line 203: Line 197:
  
  \\  \\
 +
 <code bash> <code bash>
 #!/bin/sh #!/bin/sh
Line 697: Line 692:
  \\   \\ 
 ===== Alternatives ===== ===== Alternatives =====
 +
   - Compile your own firmware with your settings hard-coded within it.   - Compile your own firmware with your settings hard-coded within it.
     - Building the compilation environment requires a lot of effort.      - Building the compilation environment requires a lot of effort. 
     - Consolidated experience with such process is necessary.     - Consolidated experience with such process is necessary.
-    - Several previous attempts were made using directions from: freshtomato-arm [[https://bitbucket.org/pedro311/freshtomato-arm/src/arm-master/README.md|README.md]] . However, these methods were **NEVER** able to generate a byte match with their own .trx build vs. .trx images prepared for general distribution in the [[https://freshtomato.org/downloads/|download repo]]+    - Several previous attempts were made using directions from: freshtomato-arm [[https://bitbucket.org/pedro311/freshtomato-arm/src/arm-master/README.md|README.md]] . \\ However, these methods were** not** able to generate a byte match between their .trx build versus \\ .trx images prepared for general distribution in the [[https://freshtomato.org/downloads/|download repository]] 
  
 ===== References and Online Resources ===== ===== References and Online Resources =====
remote_upgrade_poc.txt · Last modified: 2023/07/13 17:05 by hogwild