compression of freebsd system

Dear All,

I want to ask if there is a way to compress the free BSD kernel and what is the unnecessary files that may be removed from the free BSD system i want to minimize the size of the system .

i used the X user installation and i installed the XFCE window manager but the size is still hi i want to ask if i could compress the size of it or not?

Thanks and best regards
Mohamed Hegazy
 
you can remove modules that you don't need (there are many)
you can remove /usr/src and /usr/ports if you done need them
XFCE is pretty heavy wight....
Try installing fluxbox, fvwm or such....
how much space do you want your system to occupy?
 
Look at the respective Makefiles, there are RUN_DEPENDS and BUILD_DEPENDS. Obviously you need the RUN_DEPENDS to run the application. The BUILD_DEPENDS however are only needed to build/compile the port. They can usually be removed after you're done building the ports.

You can also look at those using make run-depends-list and make build-depends-list.

Another way to keep the volume of needed ports down is to use a separate machine (or a virtual one) to build packages of those ports yourself. Then move the packages over and install those.
 
You can delete /boot/kernel/*.symbols if you don't want to debug the kernel.
 
reply

Thanks guys for this great information , i want to run FreeBSD with only firefox, postgre database ,java ,fluxbox ,and apache ant and i don not want any thing else.

I installed those programs but i want to remove every thing that is not related to it .

Now i knew that i can remove /usr/src and /usr/ports and also some files needed to compile kernel i want to minimize the size to be about 700M , the size of the FreeBSD now is about 2.9G
The size of /usr/ports is about 550 MB
The size of /share/doc is about 300 MB

The /usr/src is not exist because i installed FreeBSD with Xuser option not developer option .

i want to ask if there is any unneeded files that i can remove .

i was thinking of take a look of installed packages and remove the uneccessary packages but i am afraid of removing the packages that may affect any thing .

Thanks and best regards
Hegazy
 
This may not help much but if you reinstall the OS again, make sure you go with minimal installation. And then just install required packages using pkg_add command. I bet it will less than 600MB for all your packages.
 
I made a test HDD image for 7.2 and installed Xfce on it along with a few applications that integrate well with it. Disk usage is as follows: 143MB for /, 531MB for /usr and 11MB for /var. And I haven't even tried to remove the "excess fat". So I guess you can easily get 700M for what you want.


mhegazy said:
The size of /share/doc is about 300 MB
You mean /usr/share/doc? It's all sorts of documents (manual, FAQ, etc.) in many languages, and FreeBSD will run fine without them, you know? Just keep the man pages (/usr/share/man) if you want some handy help.

mhegazy said:
i was thinking of take a look of installed packages and remove the uneccessary packages but i am afraid of removing the packages that may affect any thing .
You can try to remove any package you consider as unnecessary. pkg_delete will most probably refuse to remove it if it's a currently used dependency.
 
live cd

vermaden said:
@mhegazy

Download and try this LiveCD:
http://freebsd-live.org/

Its ripped as much as possible.

If you want to compress whole filesystem, then you can use compresion=on on ZFS filesystem.

Thanks for you reply

the problem with the livecd is using the databas because after restart the system no data saved .
about the compresion on the file system where could i find that option and how can i use it ?

Thanks and best regards
hegazy
 
Beastie said:
I made a test HDD image for 7.2 and installed Xfce on it along with a few applications that integrate well with it. Disk usage is as follows: 143MB for /, 531MB for /usr and 11MB for /var. And I haven't even tried to remove the "excess fat". So I guess you can easily get 700M for what you want.



You mean /usr/share/doc? It's all sorts of documents (manual, FAQ, etc.) in many languages, and FreeBSD will run fine without them, you know? Just keep the man pages (/usr/share/man) if you want some handy help.


You can try to remove any package you consider as unnecessary. pkg_delete will most probably refuse to remove it if it's a currently used dependency.

I want to make its size small as possible . i deleted the /usr/share/doc and also /usr/ports directories and now the size is about 800 MB because the java jre takes about 100 MB , but i am asking if i can comprss the size more than that .

Thanks and best regards
Hegazy
 
the problem with the livecd is using the databas because after restart the system no data saved .
I was thinking about running this LiveCD only once or twice and check out what dirs/parts of the system can be deleted.

about the compresion on the file system where could i find that option and how can i use it ?
Google for FreeBSD ZFS install.
 
Back
Top