RHEL Engineering is moving the tracking of its product development work on RHEL 6 through RHEL 9 to Red Hat Jira (issues.redhat.com). If you're a Red Hat customer, please continue to file support cases via the Red Hat customer portal. If you're not, please head to the "RHEL project" in Red Hat Jira and file new tickets here. Individual Bugzilla bugs in the statuses "NEW", "ASSIGNED", and "POST" are being migrated throughout September 2023. Bugs of Red Hat partners with an assigned Engineering Partner Manager (EPM) are migrated in late September as per pre-agreed dates. Bugs against components "kernel", "kernel-rt", and "kpatch" are only migrated if still in "NEW" or "ASSIGNED". If you cannot log in to RH Jira, please consult article #7032570. That failing, please send an e-mail to the RH Jira admins at rh-issues@redhat.com to troubleshoot your issue as a user management inquiry. The email creates a ServiceNow ticket with Red Hat. Individual Bugzilla bugs that are migrated will be moved to status "CLOSED", resolution "MIGRATED", and set with "MigratedToJIRA" in "Keywords". The link to the successor Jira issue will be found under "Links", have a little "two-footprint" icon next to it, and direct you to the "RHEL project" in Red Hat Jira (issue links are of type "https://issues.redhat.com/browse/RHEL-XXXX", where "X" is a digit). This same link will be available in a blue banner at the top of the page informing you that that bug has been migrated.
Bug 621910 - NetworkManager misses to add shortname to /etc/hosts.
Summary: NetworkManager misses to add shortname to /etc/hosts.
Keywords:
Status: CLOSED CURRENTRELEASE
Alias: None
Product: Red Hat Enterprise Linux 6
Classification: Red Hat
Component: NetworkManager
Version: 6.0
Hardware: All
OS: Linux
low
medium
Target Milestone: rc
: ---
Assignee: Dan Williams
QA Contact: desktop-bugs@redhat.com
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2010-08-06 13:25 UTC by Patrik Martinsson
Modified: 2010-11-10 19:32 UTC (History)
3 users (show)

Fixed In Version: NetworkManager-0.8.1-5.el6
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2010-11-10 19:32:14 UTC
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)

Description Patrik Martinsson 2010-08-06 13:25:18 UTC
Description of problem:

When NetworkManager changes the /etc/hosts file it simply forgets to add the short name. 

Version-Release number of selected component (if applicable):
NetworkManager-0.8.1-2.el6.x86_64


How reproducible:
Always ? 

Steps to Reproduce:
1. Set the HOSTNAME=foo.bar.baz under /etc/sysconfig/network 
2. Restart NetworkManager 
3.
  
Actual results:

cat /etc/hosts
# Do not remove the following lines, or various programs
# that require network functionality will fail.
xx.xx.x.xx	foo.bar.baz	# Added by NetworkManager
127.0.0.1	localhost.localdomain	localhost
::1	xxx.xxx.xxx	localhost6.localdomain6	localhost6

Expected results:
cat /etc/hosts
# Do not remove the following lines, or various programs
# that require network functionality will fail.
xx.xx.x.xx	foo.bar.baz foo	# Added by NetworkManager
127.0.0.1	localhost.localdomain	localhost
::1	foo.bar.baz	localhost6.localdomain6	localhost6



Additional info:
At least this is how I expected it to work, I want be able to from the same machine run 'ping shortname' and get answer from it. Now it fails. This is important to samba for example, samba is not able to perform a 'net ads dns register' if it cant get the short name from /etc/hosts file. 

You will get this message if client's shortname isn't in the hosts-file. 
"No DNS domain configured for client. Unable to perform DNS Update."

If you add the shortname after fqdn the update will succeed. 

But maybe I'm missing something ? 

Best regards, 
Patrik Martinsson, Sweden.

Comment 2 RHEL Program Management 2010-08-06 13:47:43 UTC
This issue has been proposed when we are only considering blocker
issues in the current Red Hat Enterprise Linux release.

** If you would still like this issue considered for the current
release, ask your support representative to file as a blocker on
your behalf. Otherwise ask that it be considered for the next
Red Hat Enterprise Linux release. **

Comment 3 Dan Williams 2010-08-09 19:09:03 UTC
Can you attach your /etc/resolv.conf file in this case?

Does your DNS server actually respond to requests for .bar.baz ?

Comment 4 Dan Williams 2010-08-09 19:36:56 UTC
Upstream fixes:

c72fbd6b87fde2d55c0edab66a190efcb3f9083d (master)
b16d89a340af27a3a9d4538c63e463f806b03fc4 (0.8.x)

Comment 7 Patrik Martinsson 2010-08-10 07:14:35 UTC
Hello Dan, 

Thanks for quick reply, yes the DNS server responds to .bar.baz requests.

This is the resolv.conf

# Generated by NetworkManager
domain bar.baz
search bar.baz
nameserver xxx.xxx.xxx.xxx
nameserver xxx.xxx.xxx.xxx

Best Regards, 
Patrik Martinsson, Sweden.

Comment 10 releng-rhel@redhat.com 2010-11-10 19:32:14 UTC
Red Hat Enterprise Linux 6.0 is now available and should resolve
the problem described in this bug report. This report is therefore being closed
with a resolution of CURRENTRELEASE. You may reopen this bug report if the
solution does not work for you.


Note You need to log in before you can comment on or make changes to this bug.