Every time you log into a *NIX machine you are wellcomed by a text banner that varies from one *NIX to other, even among Linux distributions.
If you want to customized this message it’s fairly easy, you only have to edit (as a root) the file /etc/motd and the next login will show your new message of the day.
My two cents to a so simple task is enrich your file writting inside some ASCII art. For instance, you may use figlet to writte inside the /etc/motd file your hostname. In short:
- Be sure you have figlet installed in your system or install: in Fedora; type yum list figlet or (lazy way) yum list figl* and figlet may appears in one of both list, installed or available package.
Add different messages to each login with fortunes. First, be sure you have fortunes installed in your Fedora and then, edit your .profile and add an invocation to the fortunes program.
For instance, I add this:
echo -n "### Fortune for "
echo -n `date +%d\-\%m\-\%Y`
echo " ###"
I get this:
### Fortune for 22-04-2018 ###
Computers are useless. They can only give you answers.
-- Pablo Picasso
BTW, I recommend to writte the full path to the fortune’s binary ’cause it’s installed out of the usual $PATH.
If you research a few over thhe Internet you may find differente fortunes collections, such The Simpsons, or my favorites inspired by BOFH.
Why am i going to “play” with a Rasperry Pi? Short answer; for educational purposes.
No the little bit more explained why I decide to sset up a Rasperry Pi, but also going to the point:
I’m very bad with hardware, so it’s a little bit challenging for me
a very good friend gift me its Raspberry Pi 1 (512Mb RAM) and it was collecting dust
I may obtain something useful at the end of the process, for instance, a media server, a little NAS, whatever.
I’m going to refresh my former sysadmin skills; file system formatting, installing different OS’s flavours, setting up a network, etc.
It’s a wide documented process so it keeps my attention in making the right thing, not in solve a new problem never before seen.
So, again, for educational purposes, mixing up fun with refreshing basic skills.
Raspian up & running on an Raspberry Pi 1 model. Reasons for Raspbian:
- Main reason: It forces me to get out of my usual Red Hat / CentOS / Fedora distro to a Debian based one. I hope this helps me in a future for getting the LP1 Certification
- General purpose (I’m not looking for a particular functinality), I’m satisfied if it acts as a ssh gateway to the rest of home network
- Well documented, this is a must since learn something new requires make mistakes. For example, I bought a USB – WiFi here you got how seting WiFi up via the command line, because command line always teches more than graphical interfaces IMHO
One of my workstations runs Fedora for a quite long. I’ve been following practices from my previous technical job and take easy to upgrade the distro or to switch the “lates-what-ever-technology” you would imagine.
I’ve finally adopt dnf command instead of yum to manage the command lines. It has being going well but suddenly I’ve started to received this error message in the terminal:
Traceback (most recent call last):
File "/bin/dnf", line 36, in
File "/usr/lib/python2.7/site-packages/dnf/cli/main.py", line 185, in user_main
errcode = main(args)
File "/usr/lib/python2.7/site-packages/dnf/cli/main.py", line 84, in main
return _main(base, args)
File "/usr/lib/python2.7/site-packages/dnf/cli/main.py", line 115, in _main
File "/usr/lib/python2.7/site-packages/dnf/cli/cli.py", line 981, in configure
self.optparser.usage = self.optparser.get_usage()
File "/usr/lib/python2.7/site-packages/dnf/cli/option_parser.py", line 255, in get_usage
usage += "%-25s %s\n" % (name, summary)
UnicodeDecodeError: 'ascii' codec can't decode byte 0xc3 in position 40: ordinal not in range(128)
So I decide to go back to the trusty well worker yum.
Finally I’ve found how to solve the problem, by typing this:
- export LANG=C
- dnf clean all
- … and then you may type
dnf clean all just is case
- Finally, type dnf update and everything must be settled and done, and your system gonna work with dnf or yum, as you wish
I got a second hand laptop -just adquired- that fulfills my requirements
- New root prompt with red background, as I explained time ago, in my opinion it must be a default configuration in order to alert you who you’re. It’s specially useful when jump from one machine to another
- Install pure flash (yes I know it’s not FLOSS)
rpm -ivh http://linuxdownload.adobe.com/adobe-release/adobe-release-x86_64-1.0-1.noarch.rpm
rpm --import /etc/pki/rpm-gpg/RPM-GPG-KEY-adobe-linux
yum -y install flash-plugin AdobeReader_enu adobe-release-x86_64
- have a look on what daemons are running in the system in order to stop all unnecesary software (Type as a root systemctl and get familiar with the command line for the new Systemd)
- Make your comfortable cozy room, custom .basrch; I’m used to add this lines (plus the
root prompt I told you before):
set -o vi
alias ll='ls -l'
I’m just to do more things, such a install my favourite browser, or few concrete software I’m devoted to, let that for a former post.
I’ve read a short and useful post from Jens Kuehnel, what to do after a Fedora upgrade and here I copy mentioning the author ’cause I’m convinced in a not too distant future I’ll be back on this advices.
- yum distro-sync
- package-cleanup –problems
- package-cleanup –orphans
- rpmconf -a -fvimdiff
Thank you Jens!