Tuesday, December 29, 2009

when pkill isn't sufficient to kill firefox

Firefox hanged and I closed it. Restarting it the message came restart or stop firefox. Pkill command normally sufficient didn't suffice to kill firefox.
pgrep firefox listed two processes.
killing these processes by kill , didn't work either.
killall -9 firefox-bin



did the trick.
source: http://www.cyberciti.biz/faq/kill-process-in-linux-or-terminate-a-process-in-unix-or-linux-systems/

for the record:

This is an oldie but a goodie:

1. When a program gets hung, hit Alt + F2 to bring up the Run dialog.
2. Type in xkill and hit enter.
3. Your mouse cursor will change into a cross or skull and bones.
4. If the unresponsive application is not in focus, use Alt-Tab to switch to it. Left click anywhere on the application window to kill it.

Thursday, December 24, 2009

Ctrl+Alt+Del to open System Monitor

In Ubuntu

If you want to enable Ctrl+Alt+Del to open System Monitor you have to do this:

Run in terminal:
gconftool-2 -t str --set /apps/metacity/global_keybindings/run_command_1 "Delete"
gconftool-2 -t str --set /apps/metacity/keybinding_commands/command_1 "gnome-system-monitor"

Monday, December 21, 2009

Manual updating grub when a new kernel is installed

If you have a manually adapted grub menu.lst ( found in /boot/grub) you will have to be very careful updating the kernel.
There will be asked if you want to keep your our grub file or the proposed one by the package distributor. Take the last choice but only after you have saved your old copy of the menu.lst as for instance menu_old.lst so that you can adapt the automatically renewed menu.lst to its former state with its renewals of the new krnel incorporated of course, but with the adaptions you made mostly to suit your own special setup on more partitions.
Do it right away before you reboot or else you will probalbly have great trouble rebooting! In terminal (or open your file manger as root)
sudo gedit /boot/grub/menu.lst

Thursday, December 17, 2009

Ifconfig and iftop and etherape network monitors

ifconfig (type in terminal) gives you good info on your network connections.
A nice terminal program is iftop. Etherape is a very informative gui program.

ifconfig

The Unix command ifconfig can function as a tool to configure a network interface for TCP/IP from the command line interface (CLI).This is another easy tool to see if your interface is actually loading correctly.

Example

ifconfig

eth0 Link encap:Ethernet HWaddr 00:0A:E6:C6:07:85
inet addr:132.18.0.16 Bcast:132.18.0.255 Mask:255.255.255.0
inet6 addr: fe80::20a:e6ff:fec6:785/64 Scope:Link
UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1
RX packets:18458 errors:0 dropped:0 overruns:0 frame:0
TX packets:8982 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:1000
RX bytes:4015093 (3.8 MiB) TX bytes:1449812 (1.3 MiB)
Interrupt:10 Base address:0xd400

Route

This is very useful to check routing config

Example

route -n

Netstat

If you want to see Routing Tables,all open ports,all listen ports

netstat -nr

-n means return numeric output (ie, IP address instead of hostname)

-r means print the routing table

find all open ports

netstat -a

find listening ports

netstat -l


http://www.ubuntugeek.com/ubuntu-network-troubleshooting-tips.html


++++++++++++++++++++++++++++++++++++++

If you use a router or gateway, chances are that your network is even further locked down. To check, you can run the following commands:

Code:
sudo apt-get install nmap curl
and then:
Code:
nmap -P0 $(curl www.whatismyip.org
The second command may take several minutes to run, but will give you an accurate picture of which (if any) ports are open to the world outside your home network.

How can you check if iptables is blocking the packets ?

sudo iptables -L

Set Open Port for iptables

sudo iptables -I INPUT -p tcp --dport <> -j ACCEPT
sudo iptables -I INPUT -p udp --dport <> -j ACCEPT

If you want to have help enabling port forwarding in your router: http://www.portforward.com/english/routers/port_forwarding/routerindex.htm

Wednesday, December 16, 2009

mounting external HDD 2

Sometimes the external hard disk drive won't mount. Maybe this is the problem:

The stupid thing you won't get a response or fault message using Storage Device Manager.
Using : sudo mount -a you will get:

Mount is denied because NTFS is marked to be in use. Choose one action:

Choice 1: If you have Windows then disconnect the external devices by
clicking on the 'Safely Remove Hardware' icon in the Windows
taskbar then shutdown Windows cleanly.

Choice 2: If you don't have Windows then you can use the 'force' option for
your own responsibility. For example type on the command line:

mount -t ntfs-3g /dev/sdb1 /media/sdb1 -o force
Trying this the HDDF is indeed mounted

Monday, December 14, 2009

logitech webcam driver

I seem to have the Logitech Quickcam Communicator.
Found a driver here
More info here

Sunday, December 13, 2009

adblock verification didn't work_Solved

Problem: adblock extension couldn't be installed because of Startcon verification failure:
Error: message: Signing could not be verified. -260.

This is essentially the solution:

ENABLE THE VERFICATION ON CERTIFICATE

  1. Start Firefox (if it isn’t already). This assumes FireFox version 3+ so menu item names below may differ for other FireFox versions but you should be able to browse to something that has a list of certificates (See image below).
  2. Go to Edit -> Preferences. New panel appears.
  3. On the new panel, click Advanced category followed by the Encryption tab then View Certificates button.
  4. Browse down to VeriSign certificates. You may see something similar to the below:
    FireFox Security Devices Config - Master Password
  5. Notice in the above image the highlighted certificate "Verisign Class 3 Public Primary Certification Authority" I’ve chosen. It matches exactly what we got highlighted in orange earlier in step 6 from first part above.
  6. Click Edit on the highlighted. You should be presented with three choices:
    This certificate can identify web sites.
    This certificate can identify mail users.
    This certificate can identify software makers.
  7. Check off "This certificate can identify software makers."
  8. Click Ok to save then Ok on other open panels or Save as the case may be and restart FireFox.
  9. Try to download your extension again. The error should be gone.
  10. You’re done!
Where I found this this was described as a solution for a problem installing a google extension
There Verisign was the verificator.
But which is the verifier for Adblock?
Here I found the answer : StartCom. everywhere you read Verisisgn replace it by Start.com and youŕe done.

Thursday, December 10, 2009

tweaking Crunchbang

The nice thing about openbox window manager is the way you can configure almost everything in easy by editing text files or some simple gui's.
I use a high resolution monitor, so I need larger fontsize. Start with Obconfig,
in #! you will find that under preferences, openbox, openbox config, GUI config tool. choose tab Appearance and change font sizes. ( Note the beautiful and clever the window buttons are configured: DSLIMC
D Omnipresent S Shade L Label I Iconify or Minimize M maximize and C Close).

This is not the only way to set lettersize; you might have lxappearence running, sometimes hidden in the menu as GUI settings; here you can set the lettersize below left on the first Window tab. Don\ t forget to use gksudo lxappearance to resize letters using gui apps as root
Lettersize in Conky by editing .conkyrc
I also ad a new image viewer toe: Ristretto and for writing Abiword.
You will have to edit the .rc.xml file for adding keybindings,

The default English keyboard is also changed to US and other localization files. See a post before this one. Don't forget to choose a local server in Synaptic for faster downloads.

Wednesday, December 9, 2009

Localize Crunchbang (in LiveUSB install)

It's kind of tricky to change the default setup which is British to Dutch for example.
Edit via sudo gedit /etc/default/locale the default language.
Local code you will find in: /usr/share/localechooser/languagelist; for instance: nl_NL.UTF-8

and then:
dpkg-reconfigure locales

For AbiWord you will need Ispell and the idutch voor spellingcontrole.
For interfaces: language-pack-gnome-nl
and language-pack-gnome-base.
Change English keyboard to us by saving us as gb in
/usr/share/X11/xkb/symbols/

There's a much easier way to set up support for other languages than
English, in particular multi-byte languages like Chinese, Korean or
Japanese: install the package "language-selector", either with
Synaptic, or with the command
sudo apt-get install language-selector

Once it's installed, you can call it with the (confusing) command

gnome-language-selector
Use the "Install/remove languages" button at the bottom to add whatever languages you want, and check the box that says "Use input method engines (IME) to enter complex characters". You can install fonts, dictionaries etc automatically this way, and set your system's interface to your choice from the languages you have installed

Solving problems with printing jobs

Most of the time everything goes well regarding printing in Linux. But when problems start they may be hard to solve.
I got some cups server error: "client-error-not-possible"
Here are some suggestions:
To be able to manage the cups printing jobs through web, you need to login first. Click on the "Administration" icon at the top of page http://localhost:631, it will prompt for user name and password.

This is also the place where you can cancel printing jobs that are hanging for some reason.

Then I noticed the printer was not active.
I already found out about this by giving this command: lpstat -t
printer HP_LaserJet_2100 uitgeschakeld sinds

On the cups webpage you can enable the printer again.
But also via terminal: lpadmin -p -E will reenable it.

Now the pinter is recongized in the HPLip Toolbox and accepts printing jobs, and gives no errors but nothing happens!!
Another solution was brought up: to install printconf.
When I had done that (sudo apt-get install printconf) I got the next error message: Unable to read printer database. Please ensure the "foomatic-db" package is installed properly.

I found the suggestion to see what drivers are available for the printer, using this command as a regular user:
foomatic-datafile -A | grep HP_LaserJet_2100

No output. Found out that installing gnome-cups-manager was sometimes an effective workaround; seems to be part of a normal install but was missing on my pc.
Recognized the printer right away. After that while printing with a gnome (Eye of Gnome) image viewer the image was printed alright. Pfff, that was easy.... no it wasn't. These are the kind of tribulations that put people off of Linux. Happily I found some many good things in linux that even printing in Windows is not a viable option anymore ;-)).

Tuesday, December 8, 2009

Install Adblocker extension for Chromium

Another reason I didn't want to use Chromium or Google Chrome was because of the ads all over the place. If you have lived years in the save hands of Adblock Plus it's unbearable to see the millions of ads coming by.

Now there is finally an adblocker extension that works with the new versions; I have version 4.0.249 (it has to be 4.+). You can install the adblocker extension here: http://www.chromeextensions.org/appearance-functioning/adblock/

After install you have to subscribe yourself manually to adblocker lists that are also used by adblock plus. You do so by clicking on the extenson icon on the upper right side , left next to control page and config button. and choose Subscribe.

More extensions here but don't use the adsweep extension, listed there; it didn't work for me.

Set minimum font in Chromium

I found Chromium unusable because of the way too small fonts om my high resolution screen until I found this tweak:

To set the minimum font size in Chromium (Linux), you must edit the ~/.config/chromium/Default/Preferences file:

gedit ~/.config/chromium/Default/Preferences


Look for this inside the file you just opened:
  },
"webkit": {
"webprefs": {
"default_fixed_font_size": 15,
"default_font_size": 16,
"fixed_font_family": "Monospace",
"sansserif_font_family": "Droid Sans",
"serif_font_family": "Liberation Serif"
}
}
}


And add this two lines under "webprefs": {
 "minimum_font_size": 16,
"minimum_logical_font_siz": 16,


If you don't see this for change the default fonts in Options Under the Hood

Sunday, December 6, 2009

Removing older kernels

Warning

Don’t follow this process unless you’re sure you don’t need to boot into the older kernels. If you’re not sure, just leave things alone. Also, it is possible to remove all of the kernels from your system and make it unbootable. I suggest leaving the latest kernel and one version previous to that. You can find out the kernel version that you’re currently running with

uname -r

Find and remove old kernels

The first step is to figure out what kernels are installed. The following command will do the job.

ls /boot | grep vmlinuz | cut -d'-' -f2,3

Your result could look something like this (running Hardy).
2.6.24-19
2.6.24-19
2.6.24-21
2.6.24-22
2.6.24-23
2.6.24-24
2.6.24-25
2.6.24-26


his is the list of kernels installed on your system. Now you want to find out which packages are installed relative to the kernel you want to remove. For my example I’m going to remove the oldest one 2.6.24-19

On my system, (JHardy) the resulting list is:

linux-headers-2.6.24-19
linux-headers-2.6.24-19-generic
linux-image-2.6.24-19-386
linux-image-2.6.24-19-generic
linux-ubuntu-modules-2.6.24-19-generic

Now that we know what packages to remove we can remove them with dpkg, apt-get or aptitude.
sudo aptitude remove linux-headers-2.6.24-19 linux-headers-2.6.24-19-generic linux-image-2.6.24-19-386 linux-image-2.6.24-19-generic linux-ubuntu-modules-2.6.24-19-generic

source:
http://tuxtweaks.com/2009/12/remove-old-kernels-in-ubuntu/

Thursday, December 3, 2009

USB_Creator also in Hardy for USB Flash Ubuntu Install

=== How to install Crunchbang to a USB flash drive using USB-Creator ===

There has been some discussion here about ways to install Crunchbang on a USB flash drive. I haven't found any mention though of using the Ubuntu program "USB Creator" for that purpose. It's very easy to do, works well and makes a persistent install to the flash drive. USB-Creator works for many Ubuntu-derived distros.

Here's how to do it:

1. Prepare a USB flash drive with a capacity of 1 GB or more, i.e. format it with a FAT32 or FAT16 filesystem and put a boot sector with MBR on it. To do that, I generally use the "Quick Format to FAT32" option of the Hewlett-Packard USB Disk Storage Format Tool, running in Windows XP (regrettably, it doesn't work in Wine). Among the many ways of setting up a flash drive, this utility seems to be one of the most reliable tools for doing this job. You can download it from http://www.pcworld.com/downloads/file/f … ption.html

Perhaps you can skip step #1 and use your flash drive as is; it may already be set up properly. I believe USB Creator merely writes the syslinux bootloader code to an already existing MS-DOS-type MBR in the boot sector; it does not reformat your flash drive, anything that's already on it will be kept.

2. Download the Crunchbang ISO and put it somewhere on an easily accessible HDD or USB flashdrive, or pull out your Crunchbang live/install CD, if you have one.

3. Boot into a v.9.04 Crunchbang, Ubuntu, Mint or other Ubuntu-derived system (either into a HDD or USB install or a live CD/DVD), install the Ubuntu usb-creator package (with its two dependencies mtools and syslinux) from the Ubuntu Universe (?) repository.

If you're using Hardy LTS like me:

It is not in the Hardy repositories;

Here are the sources:

USB Creator for AMD64

USB Creator for i386

The packages were built for Intrepid but should install nicely in Hardy. Thanks to Scot's Newsletter for the tip. The forum also reports that the latest two versions, 0.1.9 and 0.1.10, have problems; I chose to install 0.1.8 instead.

Note: USB Creator relies on syslinux and mtools so make sure to install them before installing usb-creator. usb-creator is also a plain .deb file, so you have to install it via

sudo dpkg -i usb-creator_0.1.8_all.deb

and then open the program in that distro. It's a python program, so you have to have Python installed, too.

4. In the source disc image (CD/ISO) box put the location of the crunchbang ISO or CD, in the USB disk to use box put in the location of the flash drive and then set the reserved extra space slider (for the size of the persistent overlay) to some sensible value. Click on "Make Startup Disk". The install will take less than 10 min.

5. Boot into the flash drive (you may have to change the boot sequence in your BIOS to have your computer look for and boot into any attached bootable USB device ahead of booting into the internal HDD). Any changes you make in Crunchbang (customizing applications, creating files, installing additional software, etc) will be persistent, i.e. carried forward to the next boot.

Some computers with AMD hardware may stumble over a bug in the boot code of Ubuntu 9.04 and not allow you to boot to the Desktop (e.g. see https://bugs.launchpad.net/ubuntu/+bug/366678). The workaround for this is to pull out and reinsert the flash drive after the Crunchbang splash screen has appeared.

6. The unused space within the FAT32 filesystem of the USB flash drive is freely accessible from within any OS, including Linux, Windows and MacOSX, i.e. you can put ordinary files in that space. The reserved extra space (the so-called overlay) is in the file casper-rw in the root directory of the flash drive. It can be accessed from within any other Linux distro through the command

# mount -o loop casper-rw /mnt/xyz

where /mnt/xyz is any available directory that can be used as a mount point in the currently running Linux distro. For as long as the casper-rw loopback image is mounted in that distro, you can read and write to its filesystem by going to /mnt/xyz.


sources:

http://crunchbanglinux.org/forums/topic/4287/installing-crunchbang-to-a-usb-flash-drive-using-usbcreator/

http://ubuntuliving.blogspot.com/2008/11/usb-creator-for-hardy.html


Blog Archive

About Me

Exclusion of liability Regarding StillStupid: The use you make of the guides, tips and downloads that you listed on this web site or on another website to which I refer is entirely at your own risk. In no way can I be held liable for damage or consequential damages of any kind, which occurs as a result of that use.