Bug 495361

Summary: dhclient postinstall scriptlet nukes my scripts
Product: [Fedora] Fedora Reporter: Sami Farin <hvtaifwkbgefbaei>
Component: dhcpAssignee: David Cantrell <dcantrell>
Status: CLOSED RAWHIDE QA Contact: Fedora Extras Quality Assurance <extras-qa>
Severity: high Docs Contact:
Priority: low    
Version: rawhideCC: dcantrell, wwoods
Target Milestone: ---   
Target Release: ---   
Hardware: All   
OS: Linux   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2009-04-13 21:03:56 EDT Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---

Description Sami Farin 2009-04-12 06:40:33 EDT
Description of problem:
this scriptlet, in all its greatness, renames dhclient-exit-hooks and dhclient-enter-hooks (and also other unrelated files!) so on next reboot network is not working because firewall etc. scripts are not being executed.

/sbin/dhclient-script can not find them because they are renamed to *.rpmsave and it still tries to find them at /etc !

Version-Release number of selected component (if applicable):
4.1.0-14

How reproducible:


Steps to Reproduce:
1. update dhclient+dhcp+... to rename my scripts
2. reboot
3. fail
  
Actual results:
fail

Expected results:
my scripts being intact

Additional info:
Comment 1 David Cantrell 2009-04-13 16:11:19 EDT
What scripts and configuration files did you have in place for dhcp prior to upgrading to the new package?  Did this occur on a Fedora 10 system upgrading to rawhide?
Comment 2 Sami Farin 2009-04-13 16:42:59 EDT
dhclient-enter-hooks
dhclient-exit-hooks
dhclient.conf

I don't remember what was the previous dhcp version, some 4.0.0, but how is that relevant?  "System" is also not 100% "Fedora 10", either--for example, I have not installed all of the packages, for example I have not installed the menstruation calendar program, and I have syck program from Ferora 9!  Did that answer your question?
Comment 3 David Cantrell 2009-04-13 16:54:28 EDT
(In reply to comment #2)
> dhclient-enter-hooks
> dhclient-exit-hooks
> dhclient.conf
> 
> I don't remember what was the previous dhcp version, some 4.0.0, but how is
> that relevant?  "System" is also not 100% "Fedora 10", either--for example, I
> have not installed all of the packages, for example I have not installed the
> menstruation calendar program, and I have syck program from Ferora 9!  Did that
> answer your question?  

I cannot fix the problem you are seeing unless I know what you are upgrading _from_.  In that respect, I view the question as relevant.

You are using Fedora 10 and its dhcp package?  And you have the following files for dhclient:

    /etc/dhclient-enter-hooks
    /etc/dhclient-exit-hooks
    /etc/dhclient.conf

Is this correct?
Comment 4 Sami Farin 2009-04-13 17:06:15 EDT
yes, I have dhcp + dhclient 4.1.0-14 , I had those three files you mentioned before upgrading to 4.1.0-14.
After this upgrade I restored /etc/dhclient-enter-hooks and /etc/dhclient-exit-hooks so that I could get networking working.  /etc/dhclient.conf was moved to /etc/dhcp directory and /etc/dhclient.conf does not exist now.
Comment 5 David Cantrell 2009-04-13 21:03:56 EDT
A couple of problems here, the first being that /sbin/dhclient-script isn't looking in /etc/dhcp for everything.  Fixed that.

The second are the %post scripts in the spec file.  I've modified them to do the following:

1) If you have a file in /etc that should belong in /etc/dhcp and it doesn't exist in /etc/dhcp, create a soft link to the copy in /etc.
2) Do nothing with dhc*rpmsave files.

I've done some test installs here locally with all possible dhclient hooks scripts and config files and things seem to be working fine.

Thanks for the report.  The new dhcp packages have the version 4.1.0-16.fc11.