pgrep parameters are out of order and it also needs -a to find sshd. While I'm here, simplify sh syntax and prevent noise to be printed if pid file doesn't exist
use pgrep here instead, previous way could wrongly show SSH as enabled where it isn't.
Use the same tcpdump command here that we use from the GUI, to avoid potential mismatch of info/errors.
Unbreak console menu
Make 11/111 console menu options both kill php, lighty, and then restart the GUI. Not perfect, but better than 11 not working for the times most people need it. Ticket #2709
Add a hidden menu option to forcefully kill php, lighty, and then restart the GUI. (Can't make it a part of rc.restart_webgui since killing php would also kill the script itself.)
Add the config history restore script to the console menu.
Make initial changes to allow pfSense to work in a jail.
This mostly avoids starting things that will not work and gets theinitial config. Most of the pfSense functionality will not work(pf rules, routing, etc) but it can be used for testing.
Launch running script as well
Add rc.local.running if rc.local is running so it can reattach after a console logout
Fix copy and pasto
Launch rc.local into &
Remove $id. Bump (C) date
If rc.local exists launch it
Echo out newline
Add newline after 99 menu option. Otherwise it looks very strange.
Remove \n here, it was being printed on the console. Echo should do the right thing and print a newline at the end on its own.
it's 2010, update (C)
Make menu drape across two columns saving around 10 lines of text making room for more interfaces at the top. Looks good: perry|dk & jim-p
Use sockstat, netstat might take to long under certain circumstances.
Don't kill login here. When this happens from ssh is also resets the console menu. Kill $PPID instead which should have the same intended effect.
Nuke old dev bootstrap code that is no longer in use
remove unnecessary cat
Axe the s in developers. Capitalize accordingly. Suggested by JimP
Rename PHP Shell to developers shell
Revert "Use php to detect product name on shell scripts"
This reverts commit 07881462254d007cf77c1a5b09e7a840f708657e.
Use php to detect product name on shell scripts
Add a few more *'s so that rebrands look OK
Missing "
Doh, it's sh, not php
Do not keep respawning to shell on exit. Alert box is rebooting in 5, sleep for 5 to allow CTRL-C
Use custom prompt for Recovery Shell
Spawn tcsh instead of sending getty into a DOS loop
Add missing space
Exit out to shell immediately if recovery console shell option specified.
Add hideplatform directive useful for rebranding
Use $g['product_name']
Spelling correction
Remote last_term_seen variable. It's not in use and was debugging only.
While here, cleanup the identing mess.
Allow new terminals to update last_term_seen even if they are not root.
Adding script to allow enabling / disabling of SSHD from console menu.
Change LAN ip to interface ip.
Reference correct file for upgrade from console.
Ticket #1427 - webConfigurator is a better choice, it is used everywhere else
Ticket #1427 - use webGUI instead of webConfigurator
Reset terminals on blank input which could be a console reload war between some kind of strange "new spawned console".
Launch file correctly
Add firmware update menu option which can fetch a URL from the internet or use a already fetched file from the file system.
Add pfSense php shell option. This will be used by developers to tell operators how to remove blank config options and many other things that will be easier than instructing someone to edit config.xml directly, etc.
ctrl-c is handy in the shell. Do not lock out.
Uncomment the trap statements. Now CTRL-C will kill the SSH session.
Allow CTRL-C, CTRL-Z on console, etc.
Add (y/n) hint
Explain to the user that the developer bootstrap process populates /usr/src, etc.
MFC 13617The conditional fails if /var/db/pfi/capable_* expands to more than one file as [ -f ... ] can only be used to check a single file. Use a loop with a break to get around this.
Restore previous rc.banner behavior.
Move sleep statement to do loop when option entered is ""
Helps work around - Ticket #1021
Move sleep outside of the menu loop
Increase the sleep time to counteract the tty respawn bug that is slowing down everything else since its basically fork bombing.
Add option #12 show interface info
Back out last commit. Restore CTRL-C behavior.
Do not trap on rc.inital menu
webGUI -> webConfigurator
Remove option 12. It doesn't work on Embedded.
Add option 13 to change keyboard mapping for our friends across the pond
Explain that the tailing process will exit when developer bootstrap is completed.
Explain what the development bootstrap process is doing and what to expect
If a bootstrap is in progress, offer to the user the ability to tail its progress on the console
If we encounter the job control bug then bail (logout)
Traffic -> Filter for consistency with webConfigurator
Don't sleep for 1
^ then
Run echo `tty` > /tmp/last_term_seen on startup
Remove set prompt and vidcontrol directives
Add menu option 11 text
Add option 11 - restart webgui
Send errors to the bit bucket
Switch to vty0 when user enters option 8
Carriage return before menu.
Remove extra \n
If a usb keyboard is detected, start installer with a cons25 console type
Only show option 98 if config.xml does not reside on a removable device and a msdos formatted device is present
Correct the filename
Reverse option 98 and 99
Add script that aides in creating a config.xml file on a removable device. Note that this is not fully working just yet.
Do not disable console in rc.initial. We are changing the behavior to turn off autologin.
In-discussion-with: cmbProvoked-by: Yet another complaint about old behavior
Echo before command prompt
Modify installer to be invoked from option 99
Revert commit
Do not attempt to launch the installer if the script does not exist (already installed).
Add back ) ... DOH!
RIP full C installer. We're now switching over to the BSD Installer 2.0
Clarify how to start the installer
Remove installer.lua echo but keep option intact to minimize error reports for a known non working installer
Remove top *** banner