Norman James | 422d4f3 | 2015-10-28 12:47:06 -0500 | [diff] [blame] | 1 | #! /bin/sh |
| 2 | |
Norman James | c3e77c8 | 2015-11-17 19:35:01 -0600 | [diff] [blame] | 3 | echo "Ctrl-a k to exit console" |
Norman James | 269e968 | 2015-11-17 08:59:26 -0600 | [diff] [blame] | 4 | echo "A session log is created in current directory" |
agangidi53 | 36579c4 | 2016-03-03 01:27:48 -0600 | [diff] [blame] | 5 | if screen -list | grep "hostconsole" | grep -q -i "Detached"; then |
| 6 | echo "You have an existing detached console session to host, you will be reconnected to that session" |
| 7 | fi |
| 8 | if screen -list | grep "hostconsole" | grep -q -i "Attached"; then |
| 9 | echo "You have an existing attached console session to host, you will be detached from that session and reconnected here instead" |
| 10 | fi |
Norman James | 269e968 | 2015-11-17 08:59:26 -0600 | [diff] [blame] | 11 | echo "[Enter] to continue" |
Norman James | 422d4f3 | 2015-10-28 12:47:06 -0500 | [diff] [blame] | 12 | read a |
agangidi53 | 36579c4 | 2016-03-03 01:27:48 -0600 | [diff] [blame] | 13 | screen -dR hostconsole -U /dev/ttyS5 |