Find all Deb packages currently installed

The following is a very useful command, esp before doing an upgrade:

dpkg --get-selections "*"

The following is a brief summary of the listing:

xserver-xorg-video-cirrus                       install
xserver-xorg-video-fbdev                        install
xserver-xorg-video-geode                        install
xserver-xorg-video-i128                         install
xserver-xorg-video-i740                         install
xserver-xorg-video-intel                        install
xserver-xorg-video-mach64                       install
xserver-xorg-video-mga                          install
xserver-xorg-video-neomagic                     install
xserver-xorg-video-nouveau                      install
xserver-xorg-video-nv                           install
xserver-xorg-video-openchrome                   install
xserver-xorg-video-r128                         install
xserver-xorg-video-radeon                       install
xserver-xorg-video-rendition                    install
xserver-xorg-video-s3                           install
xserver-xorg-video-s3virge                      install
xserver-xorg-video-savage                       install
xserver-xorg-video-siliconmotion                install
xserver-xorg-video-sis                          install
xserver-xorg-video-sisusb                       install
xserver-xorg-video-tdfx                         install
xserver-xorg-video-trident                      install
xserver-xorg-video-tseng                        install
xserver-xorg-video-vesa                         install
xserver-xorg-video-vmware                       install
xserver-xorg-video-voodoo                       install
xsltproc                                        install
xterm                                           install
xtrans-dev                                      install
xulrunner-1.9.1                                 deinstall
xxdiff                                          install
xz-utils                                        install
yelp                                            install
zip                                             install
zlib1g                                          install
[[email protected] droidzone]#

 


You are reading this post on Joel G Mathew’s tech blog. Joel's personal blog is the Eyrie, hosted here.

Debian apt-get broken packages

I tried to reinstall startup-manager recently after aptitude auto uninstalled it, and got the following error:

[[email protected] droidzone]#sudo apt-get install startupmanager
Reading package lists... Done
Building dependency tree       
Reading state information... Done
Some packages could not be installed. This may mean that you have
requested an impossible situation or if you are using the unstable
distribution that some required packages have not yet been created
or been moved out of Incoming.
The following information may help to resolve the situation:

The following packages have unmet dependencies:
 initscripts : Breaks: console-setup (< 1.74) but 1.68+squeeze2 is to be installed
               Breaks: nfs-common (< 1:1.2.5-3) but 1:1.2.2-4squeeze2 is to be installed
 keyboard-configuration : Breaks: console-setup (< 1.71) but 1.68+squeeze2 is to be installed
 startupmanager : Depends: python-glade2 (>= 2.12) but it is not going to be installed
                  Depends: python-gnome2 (>= 2.20) but it is not going to be installed
                  Depends: yelp but it is not going to be installed
E: Broken packages

I took a look at my apt sources list and found that as suggested I had updated the sources list to include the sid repos, which apparently did not have all the correct packages. So I commented out a few lines and fixed it.

# deb cdrom:[Debian GNU/Linux 6.0.4 _Squeeze_ - Official Snapshot i386 LIVE/INSTALL Binary 20120129-12:44]/ squeeze main

#deb cdrom:[Debian GNU/Linux 6.0.4 _Squeeze_ - Official Snapshot i386 LIVE/INSTALL Binary 20120129-12:44]/ squeeze main

#deb http://security.debian.org/ squeeze/updates main
#deb-src http://security.debian.org/ squeeze/updates main

#Additions come below:

#For module-assistant and nvidia-kernel-common
#deb http://ftp.de.debian.org/debian squeeze main contrib non-free
#deb http://ppa.launchpad.net/jtaylor/keepass/ubuntu lucid main
deb http://ftp.us.debian.org/debian stable main contrib non-free
#deb http://ftp.us.debian.org/debian sid main contrib non-free
#deb http://ppa.launchpad.net/shutter/ppa/ubuntu lucid main
#deb http://ppa.launchpad.net/echidnaman/qapt/ubuntu lucid main

The only line I left is:

deb http://ftp.us.debian.org/debian stable main contrib non-free

Followed by:

[[email protected] droidzone]#sudo apt-get update
Hit http://ftp.us.debian.org stable Release.gpg   
Ign http://ftp.us.debian.org/debian/ stable/contrib Translation-en
Ign http://ftp.us.debian.org/debian/ stable/contrib Translation-en_IN
Ign http://ftp.us.debian.org/debian/ stable/main Translation-en
Ign http://ftp.us.debian.org/debian/ stable/main Translation-en_IN
Ign http://ftp.us.debian.org/debian/ stable/non-free Translation-en
Ign http://ftp.us.debian.org/debian/ stable/non-free Translation-en_IN
Hit http://ftp.us.debian.org stable Release
Hit http://ftp.us.debian.org stable/main i386 Packages
Hit http://ftp.us.debian.org stable/contrib i386 Packages
Hit http://ftp.us.debian.org stable/non-free i386 Packages
Reading package lists... Done
[[email protected] droidzone]#sudo apt-get install startupmanager
Reading package lists... Done
Building dependency tree       
Reading state information... Done
The following extra packages will be installed:
  gnome-user-guide libwebkit-1.0-2 python-gnome2 yelp
Suggested packages:
  python-gnome2-doc
The following NEW packages will be installed:
  gnome-user-guide libwebkit-1.0-2 python-gnome2 startupmanager yelp
0 upgraded, 5 newly installed, 0 to remove and 93 not upgraded.
Need to get 5,513 kB/21.6 MB of archives.
After this operation, 60.5 MB of additional disk space will be used.
Do you want to continue [Y/n]? y

 


You are reading this post on Joel G Mathew’s tech blog. Joel's personal blog is the Eyrie, hosted here.

Where’s the trash folder in Debian?

It’s at ~/.local/share/Trash

If you wish to access it easily, create a symlink:

ln -s ~/.local/share/Trash ~/Trash

 


You are reading this post on Joel G Mathew’s tech blog. Joel's personal blog is the Eyrie, hosted here.

“Networking interface unmanaged” on Debian

I noticed this odd message “Networking interface unmanaged” in the Network icon on the system tray, which is supposed to display a list of network interfaces (at least it does that in KUbuntu). It’s impossible to manually connect or disconnect to LAN when this occurs, though an automatic DHCP connection may still be made.

Fix:

sudo kate /etc/NetworkManager/NetworkManager.conf

 

The file probably contains:

[ifupdown]
managed=false[/code]
Change false to true and restart Network Management

/etc/init.d/network-manager restart[/code]
.


You are reading this post on Joel G Mathew’s tech blog. Joel's personal blog is the Eyrie, hosted here.

Debian Error: An error occured while assessing ”. The system responded: org.freedesktop.hal

Debian Error: An error occured while assessing ”. The system responded: org.freedesktop.hal.device.volume.permissiondenied: Refusing to mount device for UUID=1000

This happens when fstab doesnt contain the correct entry. If fstab contains the entry, then a similiar message appears along with the message that fstab contains the device.

Manual fixing didnt work, so I took an advice on a forum and installed disk-manager and let it configure the entries for me. It’s in the repository.


You are reading this post on Joel G Mathew’s tech blog. Joel's personal blog is the Eyrie, hosted here.

Install HP Laserjet P1007 in Debian and Ubuntu

This was the easiest installation I’ve ever seen in a Linux distro, comparable to Windows Plug and Play

I plugged in my printer. As expected nothing happened. I tried to fathom what happened:

[[email protected] c]$ sudo tail -f /var/log/messages
Dec  7 10:49:38 debian kernel: [ 6316.051712] usb 1-7.1.2: New USB device strings: Mfr=1, Product=2, SerialNumber=3
Dec  7 10:49:38 debian kernel: [ 6316.051715] usb 1-7.1.2: Product: HP LaserJet P1007
Dec  7 10:49:38 debian kernel: [ 6316.051718] usb 1-7.1.2: Manufacturer: Hewlett-Packard
Dec  7 10:49:38 debian kernel: [ 6316.051720] usb 1-7.1.2: SerialNumber: EC0FCLS
Dec  7 10:49:38 debian kernel: [ 6316.051849] usb 1-7.1.2: configuration #1 chosen from 1 choice
Dec  7 10:49:39 debian kernel: [ 6316.635466] usblp1: USB Bidirectional printer dev 7 if 0 alt 0 proto 2 vid 0x03F0 pid 0x4817
Dec  7 10:49:39 debian kernel: [ 6316.635500] usbcore: registered new interface driver usblp
Dec  7 10:49:39 debian kernel: [ 6317.567202] usb 1-7.1.2: usbfs: interface 0 claimed by usblp while 'usb' sets config #1
Dec  7 10:49:42 debian /usr/sbin/hpljP1007: foo2zjs: Missing HP LaserJet P1007 firmware file /lib/firmware/hp/sihpP1005.dl
Dec  7 10:49:42 debian /usr/sbin/hpljP1007: foo2zjs: ...read foo2zjs installation instructions and run ./getweb P1007

That was very instructive. Ok, so I have to execute ./getweb. From where.

Since it said foo2zjs I tried to find out where foo2zjs was located

[[email protected] c]$ which foo2zjs
/usr/bin/foo2zjs

Great. So:

[[email protected] c]$ cd /usr/bin
[[email protected] bin]$ which foo2zjs
/usr/bin/foo2zjs
[[email protected] bin]$ ./getweb P1007
You need to be root
[[email protected] bin]$ sudo ./getweb P1007
sihpP1005.img

(c) Copyright Hewlett-Packard 2008

[[email protected] bin]$ sudo tail -f /var/log/messages
Dec  7 10:49:38 debian kernel: [ 6316.051712] usb 1-7.1.2: New USB device strings: Mfr=1, Product=2, SerialNumber=3
Dec  7 10:49:38 debian kernel: [ 6316.051715] usb 1-7.1.2: Product: HP LaserJet P1007
Dec  7 10:49:38 debian kernel: [ 6316.051718] usb 1-7.1.2: Manufacturer: Hewlett-Packard
Dec  7 10:49:38 debian kernel: [ 6316.051720] usb 1-7.1.2: SerialNumber: EC0FCLS
Dec  7 10:49:38 debian kernel: [ 6316.051849] usb 1-7.1.2: configuration #1 chosen from 1 choice
Dec  7 10:49:39 debian kernel: [ 6316.635466] usblp1: USB Bidirectional printer dev 7 if 0 alt 0 proto 2 vid 0x03F0 pid 0x4817
Dec  7 10:49:39 debian kernel: [ 6316.635500] usbcore: registered new interface driver usblp
Dec  7 10:49:39 debian kernel: [ 6317.567202] usb 1-7.1.2: usbfs: interface 0 claimed by usblp while 'usb' sets config #1
Dec  7 10:49:42 debian /usr/sbin/hpljP1007: foo2zjs: Missing HP LaserJet P1007 firmware file /lib/firmware/hp/sihpP1005.dl
Dec  7 10:49:42 debian /usr/sbin/hpljP1007: foo2zjs: ...read foo2zjs installation instructions and run ./getweb P1007

So it downloaded the file but again gave the same message. I decided to unplug and replug the printer.

Sure enough I was greeted by the familiar startup sound of the printer… And confirmation from syslog:

[[email protected] bin]$ sudo tail -f /var/log/messages
Dec  7 10:53:42 debian kernel: [ 6560.287745] usb 1-7.1.2: New USB device found, idVendor=03f0, idProduct=4817
Dec  7 10:53:42 debian kernel: [ 6560.287750] usb 1-7.1.2: New USB device strings: Mfr=1, Product=2, SerialNumber=3
Dec  7 10:53:42 debian kernel: [ 6560.287754] usb 1-7.1.2: Product: HP LaserJet P1007
Dec  7 10:53:42 debian kernel: [ 6560.287756] usb 1-7.1.2: Manufacturer: Hewlett-Packard
Dec  7 10:53:42 debian kernel: [ 6560.287759] usb 1-7.1.2: SerialNumber: EC0FCLS
Dec  7 10:53:42 debian kernel: [ 6560.287903] usb 1-7.1.2: configuration #1 chosen from 1 choice
Dec  7 10:53:42 debian kernel: [ 6560.290938] usblp1: USB Bidirectional printer dev 8 if 0 alt 0 proto 2 vid 0x03F0 pid 0x4817
Dec  7 10:53:43 debian kernel: [ 6561.402520] usb 1-7.1.2: usbfs: interface 0 claimed by usblp while 'usb' sets config #1
Dec  7 10:53:45 debian /usr/sbin/hpljP1007: foo2zjs: loading HP LaserJet P1007 firmware /lib/firmware/hp/sihpP1005.dl to /dev/usb/lp1 ...
Dec  7 10:53:46 debian /usr/sbin/hpljP1007: foo2zjs: ... download successful.
Dec  7 10:53:58 debian udev-configure-printer: Re-enabled printer ipp://localhost:631/printers/HP-LaserJet-P1007

Going to the printers applet, I could see a new Laserjet P1007 installed. Installed a test print.

Related info can be found here.

Install printer in Kubuntu 12.10

It was too easy. Everything was Plug and play.

However if it doesnt install for you, you can try downloading the file from HP and installing it:

First use the system script to download the driver:

/usr/bin/python /usr/bin/hp-plugin -i

Now install it:

sh /tmp/hplip-3.12.6-plugin.run --nox11 -- -i
[[email protected] droidzone]#/usr/bin/python /usr/bin/hp-plugin -i

HP Linux Imaging and Printing System (ver. 3.12.6)
Plugin Download and Install Utility ver. 2.1

Copyright (c) 2001-14 Hewlett-Packard Development Company, LP
This software comes with ABSOLUTELY NO WARRANTY.
This is free software, and you are welcome to distribute it
under certain conditions. See COPYING file for more details.

error: PolicyKit support requires DBUS or PolicyKit support files missing
(Note: Defaults for each question are maked with a '*'. Press <enter> to accept the default.)

\
-----------------------------------------
| PLUG-IN INSTALLATION FOR HPLIP 3.12.6 |
-----------------------------------------

The driver plugin for HPLIP 3.12.6 appears to already be installed.
Do you wish to download and re-install the plug-in? (y=yes*, n=no, q=quit) ?

 

sh /tmp/hplip-3.12.6-plugin.run --nox11 -- -i
Verifying archive integrity... All good.
Uncompressing HPLIP 3.12.6 Plugin Self Extracting Archive.......................................................

HP Linux Imaging and Printing System (ver. 3.12.6)
Plugin Installer ver. 3.0

Copyright (c) 2001-14 Hewlett-Packard Development Company, LP
This software comes with ABSOLUTELY NO WARRANTY.
This is free software, and you are welcome to distribute it
under certain conditions. See COPYING file for more details.

Plug-in version: 3.12.6
Installed HPLIP version: 3.12.6
Number of files to install: 50

You must agree to the license terms before installing the plug-in:

LICENSE TERMS FOR HP Linux Imaging and Printing (HPLIP) Driver Plug-in   
........................
Do you accept the license terms for the plug-in (y=yes*, n=no, q=quit) ? y

Done.

 

 

d


You are reading this post on Joel G Mathew’s tech blog. Joel's personal blog is the Eyrie, hosted here.

To do after installing Debian

The first thing I like to install is the KDE Network management widget. It is not present in Debian KDE by default.

package: plasma-widget-networkmanagement

 

Another thing noticed is the odd message “Networking interface unmanaged” instead of setting and displaying a name

Fix:

sudo kate /etc/NetworkManager/NetworkManager.conf

The file probably contains:

[ifupdown]
managed=false[/code]
Change false to true and restart Network Management
/etc/init.d/network-manager restart[/code]
.

12 hour time:

Open KDE Country. region, Language applet: Times & Dates>Time format> Change to pH:MM:SS AMPM  

Other widgets to add:

System tray (Contains volume, USB notifier etc) Task manager (this is the horizontal tab of apps)  

Favorite apps:

Shutter (screenshot manager) Gimp (Image manipulator) mc (file manager) filezilla (ftp client) gparted and parted emacs You can install all these at a go:
sudo apt-get install shutter mc filezilla gimp libx11-dev libxtst-dev emacs

libx11-dev and libxtst-dev are the dependencies of ksuperkey (along with make and build-essential).

Video thumbnails in Dolphin:

Install mplayerthumbs.

sudo apt-get install mplayerthumbs

Now enable previews in Dolphin settings>General>Previews>Video files(mplayerthumbs)

Addon scripts

Ksuperkey (Allows mapping of Win (superkey) key to the KDE app launcher, and simultaneously use  shortcuts with the key too. Follow these instructions.

 


You are reading this post on Joel G Mathew’s tech blog. Joel's personal blog is the Eyrie, hosted here.

Partition could not be mounted for UUID=1000

Solved by installing disk-manager and configuring it to make changes to /etc/fstab to make the proper changes


You are reading this post on Joel G Mathew’s tech blog. Joel's personal blog is the Eyrie, hosted here.

User is not in sudoers list

Solved by editing /etc/sudoers as root, adding:

droidzone ALL=(ALL) ALL

The proper way of editing this file is by:

su
visudo

 


You are reading this post on Joel G Mathew’s tech blog. Joel's personal blog is the Eyrie, hosted here.

Setting locales on Debian – Solving the error “Cannot set LC_CTYPE to default locale”

This is done by installing and setting locales

sudo locale-gen en_US en_US.UTF-8
dpkg-reconfigure locales

 


You are reading this post on Joel G Mathew’s tech blog. Joel's personal blog is the Eyrie, hosted here.