Hi,
In the latest vagrant box (1710.01), no man page can be found by default, altough both "man-db" and "man-pages" are installed and "rpm -V" shows nothing wrong with them.
Doing a "yum reinstall man-pages" fixes the problem, but I don't understand why, since this "rpm -q --scripts" returns nothing for it.
Best regards,
Carlos Rodrigues
Hi,
It seems I missed this bit in the release notes:
"the centos/7 images no longer include the package documentation installed by default, reducing the image size by around 70MB (you can reinstall the packages whose documentation you need)."
This makes these images troublesome for interactive use (i.e. to get a CentOS VM that we can SSH into and use normally). Please reconsider this choice. Reinstalling just about every package during provisioning to get man pages back is not a proper solution.
Best regards,
Carlos Rodrigues
On Sun, Dec 10, 2017 at 9:11 PM, Carlos Rodrigues cefrodrigues@gmail.com wrote:
Hi,
In the latest vagrant box (1710.01), no man page can be found by default, altough both "man-db" and "man-pages" are installed and "rpm -V" shows nothing wrong with them.
Doing a "yum reinstall man-pages" fixes the problem, but I don't understand why, since this "rpm -q --scripts" returns nothing for it.
Best regards,
Carlos Rodrigues
On 12/11/2017 12:37 AM, Carlos Rodrigues wrote:
This makes these images troublesome for interactive use (i.e. to get a CentOS VM that we can SSH into and use normally). Please reconsider this choice. Reinstalling just about every package during provisioning to get man pages back is not a proper solution.
I fail to understand why would you need the man pages on a server. I do not install ANY doc ( no man, no /usr/share/doc ) on any server since 2008 and I never ever felt a need for change. You need to read a man page ? Fine! Install it in the client you ssh from. Or read it online from that same client
On Sun, Dec 10, 2017 at 10:46 PM, Manuel Wolfshant wolfy@nobugconsulting.ro wrote:
I fail to understand why would you need the man pages on a server. I do not install ANY doc ( no man, no /usr/share/doc ) on any server since 2008 and I never ever felt a need for change. You need to read a man page ? Fine! Install it in the client you ssh from. Or read it online from that same client
And when the "client you ssh from" is a vagrant box running on a host that's not Linux at all? Where do I get the man pages from? Many people no longer have "properly installed" Linux clients anymore.
I see your point about leaving documentation out of servers, but that's not the point I'm making. And even in that case is debatable if that's a proper default... What if I do want (minimal) documentation on all my servers? What if that server is a jumpbox (and, therefore, the "client you ssh from" as well)? It doesn't really take that much space (and packages with significant documentation already split it into a separate package).
And there isn't any way to properly fetch the missing files, not even an easy way to know which files are missing (as "rpm -V" doesn't complain after "--excludedocs"). In this scenario, this choice just breaks existing use cases.
Best regards,
On 12/11/2017 01:07 AM, Carlos Rodrigues wrote:
On Sun, Dec 10, 2017 at 10:46 PM, Manuel Wolfshant wolfy@nobugconsulting.ro wrote:
I fail to understand why would you need the man pages on a server. I do not install ANY doc ( no man, no /usr/share/doc ) on any server since 2008 and I never ever felt a need for change. You need to read a man page ? Fine! Install it in the client you ssh from. Or read it online from that same client
And when the "client you ssh from" is a vagrant box running on a host that's not Linux at all? Where do I get the man pages from?
https://linux.die.net/man/ always worked perfectly for me. Especially when I needed the man pages while being connected from a machine running windows
Many people no longer have "properly installed" Linux clients anymore.
Right. But the effort needed to install "somewhere" a dedicated VM or container just for the docs ( assuming you cannot browse for the man page you want ) is minimal
I see your point about leaving documentation out of servers, but that's not the point I'm making. And even in that case is debatable if that's a proper default... What if I do want (minimal) documentation on all my servers?
You install it. The effort of creating a proper recipe for salt/puppet/ansible/your other automation tool of choice is close to zero
What if that server is a jumpbox (and, therefore, the "client you ssh from" as well)?
If the server is a jumpbox you definitely do not want anything but the bare minimum of packages. A jumpbox is not meant to be the repository of information you read from. I for one see that info as being better placed on the client side. But I already mentioned hat, didn't I ?
It doesn't really take that much space (and packages with significant documentation already split it into a separate package).
Takes enough to make other people ask for it to be removed :)
And there isn't any way to properly fetch the missing files,
yum -y reinstall $(rpm -qa --qf "{%name}.%{arch} " ) if you insist on doing it. But as I stated before, my use cases in the last decade never needed docs on the server side
not even an easy way to know which files are missing (as "rpm -V" doesn't complain after "--excludedocs").
Something along ls -l $(rpm -qd) works for me
wolfy
On Sun, Dec 10, 2017 at 10:46 PM, Manuel Wolfshant wolfy@nobugconsulting.ro wrote:
I fail to understand why would you need the man pages on a server. I do not install ANY doc ( no man, no /usr/share/doc ) on any server since 2008 and I never ever felt a need for change. You need to read a man page ? Fine! Install it in the client you ssh from. Or read it online from that same client
Sorry for replying to this message again, but I had delivery disabled for this mailing list and didn't get the later messages. Anyway, it doesn't really afect my point.
What you feel is not a problem because one can google for the proper information, can be a real annoyance for other people for any number of reasons. If you prefer to remove documentation from your installs, it's pretty easy to do so just by deleting a couple of directories. Not so with going the other way around.
If we were talking about an installer option defaulting to "--excludedocs" but just as easy to uncheck, I'd wouldn't even argue with you. But this is a pre-built image with this choice set in stone. The "other way around" here amounts to almost a full image rebuild.
Besides, this change happened from one 7.4 image to the next. I rebased one of my test enviroments from 1708.01 and suddenly man pages were gone with no quick way to get them back.
Best regards,
Hi,
Vagrant boxes by default should be as minimal as possible. Removing docs are one of most obvious steps to reduce size. I'm using mostly custom boxes so I didn't notice the change in CentOS default behaviour regarding man pages :(.
In my use case using some automation platform to make proper provision of boxes is overkill (reinstalling whole system might be longer than actual work that this VM will make). So according to my current knowledge, btw - any suggestions are welcome :), there are two solution what might work for you:
First one - use packer - but this is probably overkill. Second one - use vagrant package to make new box from existing one (as said you might reinstall docs), then use is as production/testing image. I tried it some time ago (I had to use packer after all).
There is great tutorial about using vagrant packer: https://scotch.io/tutorials/how-to-create-a-vagrant-base-box-from-an-existin...
But as you said - both solutions require box rebuild - second make this rebuild easy.
OFC. The drawback of both solution is that you are responsible for customization when new CentOS box/release is released (but it's still quite easy to automate).
Bests, Alex
On 12/11/2017 01:13 AM, Carlos Rodrigues wrote:
On Sun, Dec 10, 2017 at 10:46 PM, Manuel Wolfshant wolfy@nobugconsulting.ro wrote:
I fail to understand why would you need the man pages on a server. I do not install ANY doc ( no man, no /usr/share/doc ) on any server since 2008 and I never ever felt a need for change. You need to read a man page ? Fine! Install it in the client you ssh from. Or read it online from that same client
Sorry for replying to this message again, but I had delivery disabled for this mailing list and didn't get the later messages. Anyway, it doesn't really afect my point.
What you feel is not a problem because one can google for the proper information, can be a real annoyance for other people for any number of reasons. If you prefer to remove documentation from your installs, it's pretty easy to do so just by deleting a couple of directories. Not so with going the other way around.
If we were talking about an installer option defaulting to "--excludedocs" but just as easy to uncheck, I'd wouldn't even argue with you. But this is a pre-built image with this choice set in stone. The "other way around" here amounts to almost a full image rebuild.
Besides, this change happened from one 7.4 image to the next. I rebased one of my test enviroments from 1708.01 and suddenly man pages were gone with no quick way to get them back.
Best regards, _______________________________________________ CentOS-devel mailing list CentOS-devel@centos.org https://lists.centos.org/mailman/listinfo/centos-devel
On Mon, Dec 11, 2017 at 12:00 PM, aleksander.baranowski aleksander.baranowski@yahoo.pl wrote:
Vagrant boxes by default should be as minimal as possible. Removing docs are one of most obvious steps to reduce size. I'm using mostly custom boxes so I didn't notice the change in CentOS default behaviour regarding man pages :(.
I agree, images should be minimal and one can always easily install more packages during provisioning. The problem is when instead of leaving complete packages out, the size reduction is achieved by dropping files from installed packages. If man pages were segregated into their own packages, I'd have no problem with this, but they aren't for most packages.
In this case, the image dropped by 65 MB by dropping files from installed packages. Interestingly, the Fedora 27 image is still 67 MB smaller than this and it keeps the man pages. I know they're not directly comparable, but it seems to me that this goal could have been accomplished without breaking use cases.
Also, I regularly use VMs based on other distributions for this purpose as well. Currenly, among Fedora, Debian, and Ubuntu, all of them keep the man pages in their standard images. I don't know if any of those provides an alternative slimmer image where they do more than just leaving complete packages out, but that's certainly an option.
In my use case using some automation platform to make proper provision of boxes is overkill (reinstalling whole system might be longer than actual work that this VM will make). So according to my current knowledge, btw - any suggestions are welcome :), there are two solution what might work for you:
Provisioning your own images is an alternative, yes. But doesn't that defeat the point of these images? Aren't they supposed to be generic images to cover most use cases? I think spinning short-lived VMs for interactive use is certainly a common use case. That's the use case I'm arguing for.
Some of the files in the "/usr/share/doc" may be required for compliance with some packages' licensing during distribution. I have no concrete examples of this, it's just something that occured to me.
C.
Hi,
On 12/11/2017 03:59 PM, Carlos Rodrigues wrote:
In this case, the image dropped by 65 MB by dropping files from installed packages. Interestingly, the Fedora 27 image is still 67 MB smaller than this and it keeps the man pages. I know they're not directly comparable, but it seems to me that this goal could have been accomplished without breaking use cases.
https://app.vagrantup.com/generic/boxes/fedora27 - 800+M https://alt.fedoraproject.org/cloud/ Fedora Cloud image is about 250M (website says it's 199 ;)).
I make quick comparision with my_query_format="%{NAME}\n" && rpm --qf $my_query_format -qa | sort on Fedora 27 cloudimage and generic/centos7
One of the packages that definitely requires removal is centos-logos. I' will make separate thread on this mailing list.
Bests, Alex
On Mon, Dec 11, 2017 at 4:14 PM, aleksander.baranowski aleksander.baranowski@yahoo.pl wrote:
https://app.vagrantup.com/generic/boxes/fedora27 - 800+M https://alt.fedoraproject.org/cloud/ Fedora Cloud image is about 250M (website says it's 199 ;)).
I make quick comparision with my_query_format="%{NAME}\n" && rpm --qf $my_query_format -qa | sort on Fedora 27 cloudimage and generic/centos7
One of the packages that definitely requires removal is centos-logos. I' will make separate thread on this mailing list.
I'm using the one at "https://app.vagrantup.com/fedora/boxes/27-cloud-base". It's 253M and I assume it's the same one from "alt.fedoraproject.org".
C.
Hi,
On 12/11/2017 03:59 PM, Carlos Rodrigues wrote:
Also, I regularly use VMs based on other distributions for this purpose as well. Currenly, among Fedora, Debian, and Ubuntu, all of them keep the man pages in their standard images. I don't know if any of those provides an alternative slimmer image where they do more than just leaving complete packages out, but that's certainly an option.
This is very solid point.
Provisioning your own images is an alternative, yes. But doesn't that defeat the point of these images? Aren't they supposed to be generic images to cover most use cases? I think spinning short-lived VMs for interactive use is certainly a common use case. That's the use case I'm arguing for.
Fedora generic (generic/fedora27) image is about 800M. Only cloud images from https://alt.fedoraproject.org/cloud/ are so light.
Some of the files in the "/usr/share/doc" may be required for compliance with some packages' licensing during distribution. I have no concrete examples of this, it's just something that occured to me.
I never heard about that, but it might be true.
I made some quick comparison with fedora27 cloud image.
my_query_format="%{NAME}\n" && rpm --qf $my_query_format -qa | sort And found out that there is package that probably should be removed - centos-logos, it's about 22MB when installed, probably less for image size.
rpm -qa --queryformat '%{SIZE} %{NAME}\n' | sort -rn CentOS comes with linux-firmware Fedora without. This package is about 126M when installed. I don't have any knowledge about indispensability of this package.
Bests, Alex
On Mon, Dec 11, 2017 at 4:32 PM, aleksander.baranowski aleksander.baranowski@yahoo.pl wrote:
Some of the files in the "/usr/share/doc" may be required for compliance with some packages' licensing during distribution. I have no concrete examples of this, it's just something that occured to me.
I never heard about that, but it might be true.
I've checked Ubuntu and Fedora packaging rules. Both say that packages must contain license files (in "/usr/share/doc" or as symlinks to common files for popular licenses). In fact, Fedora's rules for the cloud image state:
"Use new %license macro to separate license files from documentation, so the latter can be excluded from container images without stripping license information which must be included."
https://fedoraproject.org/wiki/Changes/Use_license_macro_in_RPMs_for_package...
I was actually going to suggest that using "%_netsharedpath /usr/share/doc" instead of "%_excludedocs 1" (thus leaving man pages intact, which are just 20MB or so) might be a decent middle ground, but looking at these rules it seems upstreams want to make sure that license files are never left out. I didn't find a way to exclude files using a pattern, only by prefix.
rpm -qa --queryformat '%{SIZE} %{NAME}\n' | sort -rn CentOS comes with linux-firmware Fedora without. This package is about 126M when installed. I don't have any knowledge about indispensability of this package.
I removed it from a test VM and didn't notice any problems. It may be necessary for some devices that can be bypassed from the host into the VM, but I'd be suprised if the emulated virtualbox hardware required a firmware upload.
C.
On 12/10/2017 06:13 PM, Carlos Rodrigues wrote:
On Sun, Dec 10, 2017 at 10:46 PM, Manuel Wolfshant wolfy@nobugconsulting.ro wrote:
I fail to understand why would you need the man pages on a server. I do not install ANY doc ( no man, no /usr/share/doc ) on any server since 2008 and I never ever felt a need for change. You need to read a man page ? Fine! Install it in the client you ssh from. Or read it online from that same client
Sorry for replying to this message again, but I had delivery disabled for this mailing list and didn't get the later messages. Anyway, it doesn't really afect my point.
What you feel is not a problem because one can google for the proper information, can be a real annoyance for other people for any number of reasons. If you prefer to remove documentation from your installs, it's pretty easy to do so just by deleting a couple of directories. Not so with going the other way around.
If we were talking about an installer option defaulting to "--excludedocs" but just as easy to uncheck, I'd wouldn't even argue with you. But this is a pre-built image with this choice set in stone. The "other way around" here amounts to almost a full image rebuild.
Besides, this change happened from one 7.4 image to the next. I rebased one of my test enviroments from 1708.01 and suddenly man pages were gone with no quick way to get them back.
Agreed that it can be an issue, which is why you can install them if you like. Devs asked for no man pages, we gave it to them. I think maybe other distros do this as well for an 'as lean as possble' dev environment.
This is venue to discuss that .. so if others think this is major issue that needs to be addressed, use this thread.
But personally, I think the purpose of vagrant boxes is basically a quick dev environment and one of the most important features a vagrant box is small size so that when you spin up hundreds or thousands of them a day, they minimize bandwidth and download time while getting a functional environment.
If enough people disagree with that, then it can likely be addressed.
Thanks, Johnny Hughes