LinuxReviws.org --get your your Linux knowledge
> Linux Reviews >

Tips and Tricks

Quick and simple tips for a more productive day.

How to browse the Internet using the Mozilla 1.x and Mozilla Firefox browsersHow to browse the Internet using the Mozilla 1.x and Mozilla Firefox browsers
Learn how you can filter away advertisements, make the fonts look nicer, ensure your privacy is not violated and more. Read on to discover the hidden secrets features of Mozilla 1.6+ and Firefox 9.x.
more >>>

Turning Screensavers and Monitor Power saving on/offTurning Screensavers and Monitor Power saving on/off
How to turn automatic powersaving features on and off
more >>>

Screenshot grabbingScreenshot grabbing
How to make a screenshot of your desktop or an application
more >>>

Playlist generationPlaylist generation
Simple shell script for generateing playlists
more >>>

Simple calculatorsSimple calculators
The basics of the calculators you (probably) have installed
more >>>

Things you may find handy to know

How to get bash to clean the screen after logging out?

echo "clear" >> .bash_logout

The file .bash_profile is loaded when you login. You can place aliases here. The file .bash_history keeps track of your last commands.

Mozilla and Firefox

  • You can at any point press ctrl-l in Mozilla and Firefox to get to the location bar. ctrl-l and Enter will reload the page (like ctrl-r).
  • ctrl-b gives quick access to bookmarks
  • ctrl-f lets you search the current page
  • ctrl-u will show you the page sources

Simply run "xine /misc/cdrom" to play whatever content is on a CD with xine.

Cut and Paste in X

You can select any text in X-Windows using the mouse and instantly paste it by clicking on the third mouse button. Two button mouse users emulate three by pressing both. On modern mice the third button is commonly found on the mouse wheel.

Using bash and other shells

  • Press tabulator to complete commands, filenames and other things. Try pressing the tabulator key after just two or three letter whens entering commands and filenames. If you want the command xscreensaver in a shell you can simply type xscr and press tab. When lazy, try tab. Tab also works in GTK file dialog boxes.

How do I change the resolution in X?

You can change your resolution on the fly in X with the tool xrandr. This is a command line utility. You can do this in Gnome from the control panel.

KDE has a nice frontend called krandrtray. It can be used with most window managers, like fluxbox. krandrtray allows you to change Hz, resolution and control power saving features.

You can also change your resolution on the fly with ctrl + alt + + and ctrl + alt + -.

kate - kde text editor

Writing a list in kate? Press ctrl + enter instead of just enter at end of a line to start a the next new line with the beginning of the previous line.

X11 - Use the keyboard as mouse

You can turn mouse emulation on/off by pressing shift+num-lock. This allows you to use the number keypad as a mouse.

Is someone bothering and messing with you?

Then find their IP address in your logs and simply add this to your iptables firewall:

  BADIP="24.83.73.244"
  iptables -A INPUT -i all -s $BADIP/24 -j DROP
  • -A regelsett
  • -i nettverkskort, navngitt all, eth0, eth1
  • -s kilden, nettverket eller IP som vi skal filtrere etter
  • -j hva som skal gjøres. ACCEPT, DNAT og i dette tilfellet DROP.

Bruk iptables -L -v for å se gjeldene regelsett. Noen system vil automatisk lage dine iptables innstillinger ved utlogging.

  • Gentoo brukere kan kjøre /etc/init.d/iptables save for å lagre gjeldende innstillinger.
    • IPv6: /etc/init.d/ip6tables save
  • Fedora brukere kan gjøre service iptables save for å lagre gjeldende innstillinger.
    • RPM pakken iptables-1.2.9-2.3.1 for Fedora inkluderer ikke ip6tables.

You should make sure you have a firewall running with strict rules.

You can ensure that it is started at boot with the following commands:

  • Gentoo: rc-update add iptables default
    • IPv6: rc-update add ip6tables default
  • Fedora: chkconfig --level 35 iptables on

Meet new people