how to change dpkg installation directory?

Derek Broughton derek at pointerstop.ca
Thu Jun 18 00:40:11 UTC 2009


H.S. wrote:

> Bram Kuijper wrote:
>> Hi all,
>> 
>> I want to change the default directory into which dpkg installs my
>> applications, since I have too little space on my rootdisk. However, I
>> changed the necessary configuration in /etc/dpkg/dpkg.cfg, but now
>> nothing will install anymore. What should I do?
>> 
>> This is what I did:
>> In /etc/dpkg/dpkg.cfg i added the following line:
>> instdir /media/disk-4/bram/root
>> 
>> This directory is writable by root.
>> 
>> Then I did:
>> dpkg --configure -a
>> 
>> works perfectly.
>> 
>> Then I installed some program, let's do java:
>> sudo apt-get install openjdk-6-jre
> 
> 
> dpkg specifically has two flags for this kind of stuff:
> --admindir
> --instdir

That's exactly what he did - but it's the wrong thing to do...  Putting 
"instdir" in the .cfg file is exactly the same as putting it on the command 
line.
-- 
derek






More information about the ubuntu-users mailing list