-
Senior Member
registered user
Apt-get / dpkg tutorial
I have been using debian for ages, but I still don't know all the tricks or how to use all the advanced apt / dpkg features, and I didn't need to with debian. But because knoppix has a somewhat difficult package selection, having a list of the common commands could be handy to answer questions on this forum.
I'm talking about stuff like how to "hold back" a package, how to install one from a particular release etc.
So here goes, help me out here.. Hope this can be come a quick reference.
To list all the files in a package
Code:
dpkg -L packagename
to install a package of a particular release ( assuming it's in your sources.list )
Code:
apt-get install -t unstable packagename
-
Senior Member
registered user
-
apt and dpkg commands
To put a package on hold
Code:
echo packagename hold | dpkg --set-selections
To take a package off hold
Code:
echo packagename install | dpkg --set-selections
To list the version of an installed package
Code:
apt-cache policy packagename | grep Installed
To list packages containing a certain string in its package name, version or description
Code:
COLUMNS=120 dpkg -l | grep string
HTH,
orth
-
Senior Member
registered user
Tells the status (hold, purge etc..) of the package.
Code:
dpkg --get-selections <package name>
To show anything in database with the package name.
Code:
dpkg -l ¦ grep <package name>
To deinstall the package with all configuration files.
Code:
dpkg --purge <package name>
To save or edit your packages status use dpkg --get-selections > current_selections.txt re-directs your packages to the file, to restore list dpkg --set-selections < current_selections.txt then apt-get update to refresh then apt-get upgrade to make the changes , also can be used to keep your current settings on any install just restore the list to the new install and apt-get update and upgrade or dist-upgrade and you will have the same software packages on the new install.
apt-cache showpkg <package name>
This command will display the dependencies of the package and what the package provides
apt-cache search <package name>
This command will search the package cache and display packages that have a relation to the package.
Usefull apt options -s simulate the action of apt-get the --purge option will purge the configuration files when removing a package(s).
-
list contained files
How to list contained files in dselect or aptitude? Or is there any other package management having that feature?
-
Senior Member
registered user
synaptic (and apt-get too) only want to remove KDE 3.1.2, instead of upgrading to 3.1.3... ??? why, wazzup?
-
Junior Member
registered user
somebody please show me how to upgrade kde once i installed knoppix in my hdd. i'd like to install it and get kopete since gaim still cannot connect to yahoo. pretty please?
-
Senior Member
registered user
Originally Posted by
popuman
somebody please show me how to upgrade kde once i installed knoppix in my hdd. i'd like to install it and get kopete since gaim still cannot connect to yahoo. pretty please?
Do you really need to update KDE for this.
If you're having problems getting kopete, just try this.
apt-get update
apt-get -t unstable kopete
Post back if that works.
-
Junior Member
registered user
thanks. complied with instructions. output was: E:Invalid operation kopete
help? please?
-
Senior Member
registered user
aay made small mistake: the command should be:
Code:
apt-get -t unstable install kopete
(note the "install", thats the missing command apt-get complained about
you could've found that out easy by reading the man about apt-get... THATS how you learn, not by asking us...
how to get info about a command?
so
gives manual of apt-get. you can use this for every command!
good luck...
Similar Threads
-
Replies: 10
Last Post: 11-04-2004, 09:00 AM
-
By Nitromethane1261 in forum General Support
Replies: 2
Last Post: 09-15-2004, 12:09 AM
-
By Firezone2k in forum General Support
Replies: 1
Last Post: 11-26-2003, 05:46 AM
-
By senorian in forum The Lounge
Replies: 0
Last Post: 04-12-2003, 08:40 PM
-
By mabhatter in forum Ideas
Replies: 1
Last Post: 03-04-2003, 07:42 PM
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
***NEW*** BCM RX67Q Gaming Motherboard | Intel Q67 2nd/3rd Gen. | LGA1155 | DDR3
$29.77
ASUS H110M-R Motherboard Intel 6th/7th Gen LGA1151 DDR4 Micro-ATX i/o shield
$42.00
Micro ATX Desktop Motherboard ASUS H110M-C LGA 1151
$31.95
MSI A320M-A PRO AM4 AMD A320 USB3.2 Gen1 Micro-ATX Motherboard
$46.99
Gigabyte GA-B75M-HD3 Intel LGA1155 DDR3 Desktop Motherboard MicroATX USB 3.0
$26.99
Gigabyte AMD B550 UD AC Gaming Motherboard - AMD B550 Chipset - AM4 Socket - AMD
$89.99
ASUS Prime Q270M-C LGA1151 DP HDMI VGA SATA 6GB/s USB 3.0 MicroATX Motherboard
$37.99
ASUS Prime Z390-A LGA 1151 Intel Z390 SATA USB 3.1 ATX Motherboard NO I/O
$99.00
BTC-S37 Mining Motherboard Kit /w SSD & Ram Preinstalled
$59.99
MSI ‎B550M PRO-VDH WIFI Socket AM4 AMD Motherboard
$80.00