ALE / KSU-IEEE
- email lists - General, Jobs, Study http://ale.org/
- IRC #ale on Freenode
- Meetup.com - “ale linux atlanta” search
- Weekly Sunday Meetings (NW - Smyrna)
- Weekly Tuesday Meetings (SW - Fairburn)
- Monthly Tueday Meetings (Decatur Makers)
Patch that sh/t and keep your piles on some other storage
Or ...
Desktop Maintenance and Backups for Linux Desktops
Thanks for coming out!
Blog: blog.jdpfu.com
email: DJPfulio -@- jdpfu.com – JD (former rocket scientist)
We are 100% Volunteers.
Any Questions?
- Any questions about the reading assignments?
- Linux for Windows Users
- Linux is NOT Windows
- You've been using Linux for a week now.
- Any Questions?
I'll make mistakes.
- There are usually 50-500 different ways to solve anything
- I will know a few, but definitely NOT all of them.
- I’d guess I know about 10% of “Linux” after 24 yrs
- At this level, have to provide guidelines and may loose 100% techincal accuracy
Linux for Windows Users
- Linux for Windows Users
- Most things are case-sensitive; programs should handle it, but some do not
- Don't download, manage, install programs like Windows.
- Use a Repo - from a reputable source
- Best to avoid spaces/weird characters in file and directory names.
- Never forget that all Unix-like OSes are multi-User
- Weekly patching and Daily Backups
No GUI Stuff Here
Power Users
- GUIs are slow.
- GUIs cannot be easily automated. Inconsistent.
- GUIs don't work on Servers. Why learn stuff twice?
- No certifications for GUIs. There are for Servers.
- The CLI/Shell is repeatable.
- GUIs change every 2 yrs.
RTFM and Google Everything
- No spoon feeding here.
- Expect you can find answers yourself.
- Hard part is asking the question in the Linux-way / Unix-way.
- None of the software we discuss will be commercial (will be F/LOSS)
- Paid software is a Microsoft and Apple thing, not so much on Linux.
- Google-Fu: ubuntu 16.04 {issue}
Patching
- Do it weekly.
- Reputable distros will have something to patch at least that often.
- Usually, no reboot is needed, but ... if there is a new kernel, reboot.
- Rebooting is for Windows or new kernels (mostly).
Distro Releases Explained
- Ubuntu LTS = 3 or 5 Years of Support
- Debian "Stable" means ~2+ yrs of support
- Unstable - bleeding edge
- Testing - will be the next stable ... eventually.
- CentOS - follow RHEL support … in general, moving from 7.1 → 7.2 → 7.3
- CentOS 7 - June 30, 2024
- CentOS 6 - 2020
- Fedora - bleeding edge
- 350-450 days of patches
- expected to move to the next release when available
- Redhat CEO uses Fedora 26
Weekly Patching - Debian/Ubuntu
- Ubuntu
- $ sudo apt update && sudo apt upgrade
- $ sudo apt update && sudo apt full-upgrade # replaces old packages
- Debian
- $ sudo apt update && sudo apt upgrade
- $ sudo apt update && sudo apt full-upgrade # replaces old packages
- Can enable automatic security patches.
- What might the downsides be?
Neomenclature
- $ - normal userid
- # - root userid
- If I use terms you don't know - ASK
Weekly Patching - CentOS/Fedora
- Automatic Updates:
- dnf install dnf-automatic
- /etc/dnf/automatic.conf
Linux Logs – When Things Fail
- Always check the log files.
- In /var/log/* - text files.
- sudo egrep -i 'error|warn' /var/log/*log
- systemd uses binary logs, but today those are converted to text for backwards compatibility.
Backups
- Basic Skill
- 2 Types of backups
- Stored in 3 physical locations
- Network and storage efficient
- Encrypted
- Automatic
- Restore must be tested. Hope is not a plan.
Virtual Machine Backups
- File → Export Appliance
- This is a clone.
- Very Inefficient.
- Only works with VMs
- Need 2 things – the VM settings and the virtual hard disk.
Baby Physical Machine Backups
- Works for virtual machines too.
- Can clone using clonezilla, partimage, dd, ddrescue, fsarchiver.
- Mirror files using rsync – 1 copy
Expert Physical Machine Backups
- Automatic (if no GUI is uses via crontab)
- Very efficient
- 30 days is 1.15x the original size – 10G → 15G for 30 days of daily backups
- 50 different solutions
Backups – What Needs to be Backed Up?
- Data is NOT enough.
- files, permissions, ownership, groups
- Might want ACLs
- System Settings - partitions, LVs, /etc/, ...
- HOME
- Any system-level data - /var/html/, /var/lib/Dbs…
- Perhaps a list of installed Packages
Backups – An Example
# rdiff-backup --exclude-special-files \
root@some-other-server:/ \
/Backups/some-other-server/
- Put that into a script; chmod +x the script.
- setup ssh between the backup-server and the client machines (always "PULL")
- Run the script from a root crontab - 2am is a good time
Every Saturday until mid-November
- except Oct 14th and Nov 18th
- 10a until noon-ish
- 5 min break around 11a.
Feedback?
Email me or let your IEEE team know.
Linux Runs Everywhere
- Tiny $5 computers
- 1,000 node supercomputers
- smartphones
- tablets
- video players
- desktop and servers
- Linus
- Usenet Post in 1991
Peter H. Salus said:
- Write programs that do one thing and do it well.
- Write programs to work together.
- Write programs to handle text streams, because that is a universal interface.
Mike Gancarz said:
- Small is beautiful.
- Make each program do one thing well.
- Build a prototype as soon as possible.
- Choose portability over efficiency.
- Store data in flat text files.
- Use software leverage to your advantage.
- Use shell scripts to increase leverage and portability.
- Avoid captive user interfaces.
- Make every program a filter.
Linux Applications
- LibreOffice
- Browsers - Chromium/Firefox/Lynx/Opera/ ... 30 others
- Image Viewers - geeqie
- Video Players - vlc, smplayer, mpv, totem, ffmpeg
- Email - Thunderbird, mutt, alpine, ...
- Image Manipulation - Gimp, Imagemagick, ...
- AlternativeTo.net
- To be more efficient, think in the Unix-way.
More than 1 Way, usually 50-500 ways
- User is KING!
- Users are expected to build tools to solve problems, using other
tools.
Where are Things Usually - File System Hierarchy
/home
/
/etc
/root
/bin
/usr
Listing Files/Directories
Viewing Files
- more / less
- cat
- editors ... vi, nano, gedit, kate, geany
Copying, Moving, Renaming Files
Finding Files
- locate/updatedb
- whereis
- which
- find
Command Line Editing / Efficiency
- {tab} completion
- arrows
- -arrows
- history
RTFM Already
- man man
- man -k {command} / apropos
- man -s 5 {...}
- man -s 8 {...}