- Partial backup of the database
sudo mysqldump --no-data zabbix > zabbix_backup.sql
#!/usr/bin/env bash | |
# Set API key env variable like: | |
# export NETBOX_API_KEY="blahblahblah" | |
# Usage: ./Add_Netbox_User NETBOX_HOST USERNAME FIRST_NAME LAST_NAME EMAIL GROUP_ID PASSWORD | |
# Example: ./Add_Netbox_User netbox.example.com will.riker William Riker [email protected] 1 TroiFan1 | |
if [[ -z "$NETBOX_API_KEY" ]]; then | |
echo "Must provide NETBOX_API_KEY in environment" 1>&2 | |
echo " Example: export NETBOX_API_KEY='blahblahblah'" 1>&2 |
# /root/newuser.sh | |
# | |
# Create and use a new user every time you log in. | |
# | |
# Setup: | |
# ~$ nano newuser.sh | |
# *paste contents of this file and save* | |
# ~$ chmod +x newuser.sh | |
# ~$ echo "bash newuser.sh" >> ~/.profile |
I often find myself using Byobu on a Linux machine when connected to it over SSH. In doing so, I've noticed that many of the documented keyboard shortcuts don't work. This can be due to the native PC's OS intercepting certain keys, or possibly other reasons.
Below is a cheatsheet with Byobu features I have found usually work when run over a SSH connection.
Action | Windows + Putty to Ubuntu | MacOS + Terminal to Ubuntu |
---|---|---|
Help menu | BASH: byobu-config | FN-F1 |
Create new window | CTRL-a c | CTRL-a c or FN-F2 |