Review of some useful sysadmin-utilities
Gnu Midnight Commander (mc for short)
MC is a ncurses-based file manager. Its biggest advantage is the use of two panels, with each representing a directory. This allows you to copy, move or link files from one panel (representing a dir) to the other, or visually compare two directories. On the lower side of your screen is a normal command line, only MC adds some extra commands, like copying the name of the selected file in your panel, to the command line. It has an embedded text editor, which remembers the position after you have edited a file. It also includes viewing ftp/samba directories and zipped files as normal directories. MC offers you pre-defined macros, and the option to add macros yourself. With macros, you can use MC's own reversed variables, like %d which represents the current selected directory, for example. MC has a lot of keyboard shortcuts, which enables you to work really fast once you know them.
Sometimes, you have the task of renaming many file names. For example, you want to convert all spaces to underscores, change the letters in extensions, or number files. For this goal, the folks of KDE came up with krename. You don't have to install the entire KDE desktop to use it, since it works in any window-manager. It is almost the same as the rename-feature in the Total Commander which runs on windows, only better. You choose which files you want to rename, and then the old and new names appear in a window. After that, you can use a sorting to specify ranges, upper- or lowercase, numbering etc.. Instead of just renaming, you can also make symbolic links, or change the permissions, using plugins.
If you don't like the graphical Xcalc, but need to do some quick calculations from time to time, try bc. It's a command line arbitrary precision calculator, capable of processing standard input and even scripts. it's a nice tool for converting hexadecimal and decimal numbers. It supports statement structures like "for and while" loops, and can be configured to show any number of digits. The 'last' variable contains the value of the last answer, bc has a command history, and you can use 'read' in bc-scripts to ask for user input and work with that input.
Sudo is like a replacement for "su -c". It executes a command as another user, which defaults to root. The biggest advantage is the configuration file. It is very flexible, well documented, and allows for making groups of commands, groups of users allowed to run groups of commands, to specify if a user needs the root password to use sudo or just its own, mailing the system-administrator about failed passwords, and more. Wildcards can be used in the config-file. Since you are changing user, sudo also enables passing through environmental variables. If set up correctly, a normal user enters the sudo command, then, unless the policy says no password is needed, the user is asked for his own/root password, and after that, a time stamp is created and the command is executed. As long as the time stamp is valid, which is fifteen minutes by default, sudo can be used without re-typing the password.
Nmap is a network scanning tool. It is mainly used to scan IP-ranges and port ranges, but can also serve to find out if others can scan what software you are using. If you want to know what ports are open on your computer, just do 'nmap localhost' and you're done. But, a more interesting use, is scanning other computers, to see if their firewalls work, how high the TCP-sequence predictability is, and how fast they response to a scanner like nmap (if scanning takes a long time, crackers might give up). One of the funniest things of nmap is, it can be used to scan which operating system a website is running. This feature has also a usable goal: you can try to hide your OS characteristics, and after that, try scanning with nmap to see if you succeeded. If crackers can't figure out which OS you are using, it will be more difficult to find an exploitable vulnerability for your OS-version.
Anyone who ever tried manually editing the samba configuration file smb.conf, knows this can be a very daunting task. There are very many options, which are almost impossible to remember. For this purpose, samba usually comes with a graphical web interface, called swat. It can be accessed via a browser, and after you entered the samba-password, you arrive at the page with all documentation. Using the buttons on the top, you can change global options, change and create shares, manage printers, and watch or restart the nmb and smb daemons. In globals and shares, you can click on the button Change view to "Advanced" to view and configure all options. If you're unsure about an option, all options offer a link pointing to the documentation of that option. If you click on the View button in the top-bar, you can view the smb.conf file swat has created for you.
lm_sensors & wmgtemp
Do you ever wonder how warm your computer is? Lm-sensors is the program which can get the temperature from the sensors. First, you need to configure your kernel with i2c support, and then you can install lm-sensors. The sensors-detect program will then tell you what actions you should take to get lm_sensors working. Lm_sensors is mainly a backend; to use it, you need a frontend. My favourite is wmgtemp for WindowMaker. It is very small, and shows nothing more than the system- and CPU temperature. If the two temperatures are switched by accident, wmgtemp can exchange them. As an interesting option, you can add a critical temperature above which a 'red light' shows up in wmgtemp.
Basically this is no application but a web page, but it can be very helpful anyway when forwarding ports through routers. All it does, is scan if a port on your computer can be reached through the Internet. Lets say you just forwarded SSH through your ADSL router, and want to know if port 22 can be reached, you just enter port 22; you don't need to give your IP-address. It then scans that port and returns an error, or success.
|Subject||Topic Starter||Replies||Views||Last Post|
|When I set up a server I use Debian.||tadelste||41||1,767||Dec 1, 2005 3:51 PM|
You cannot post until you login.