Warning: Function ereg() is deprecated in ..../includes/class_postbit.php(345) : eval()'d code on line 4

Warning: Function split() is deprecated in ..../includes/class_postbit.php(345) : eval()'d code on line 19

Warning: Function ereg() is deprecated in ..../includes/class_postbit.php(345) : eval()'d code on line 4

Warning: Function split() is deprecated in ..../includes/class_postbit.php(345) : eval()'d code on line 19

Warning: Function ereg() is deprecated in ..../includes/class_postbit.php(345) : eval()'d code on line 4

Warning: Function split() is deprecated in ..../includes/class_postbit.php(345) : eval()'d code on line 19

Warning: Function ereg() is deprecated in ..../includes/class_postbit.php(345) : eval()'d code on line 4

Warning: Function split() is deprecated in ..../includes/class_postbit.php(345) : eval()'d code on line 19

Warning: Function ereg() is deprecated in ..../includes/class_postbit.php(345) : eval()'d code on line 4

Warning: Function split() is deprecated in ..../includes/class_postbit.php(345) : eval()'d code on line 19

Warning: Function ereg() is deprecated in ..../includes/class_postbit.php(345) : eval()'d code on line 4

Warning: Function split() is deprecated in ..../includes/class_postbit.php(345) : eval()'d code on line 19
changing hostname with out fouling up network connection?
Results 1 to 6 of 6

Thread: changing hostname with out fouling up network connection?

Hybrid View

  1. #1
    Newbie
    Join Date
    Jul 2008
    Location
    North-Central California USA
    Posts
    4

    changing hostname with out fouling up network connection?

    Any suggestions on changing the hostname without fouling up the network connection? All the posts I have google'd warn of messing up the network connection if the hostname is changed, but I'm still not clear on the whole solution. Please don't hesitate to ask if I can provide more information, especially about the network connection. Thanks!

  2. #2
    Moderator
    Advisor
    redhead's Avatar
    Join Date
    Jun 2001
    Location
    Copenhagen, Denmark
    Posts
    811
    change /etc/hostname as you like, then run the command
    #hostname <new_hostname>
    and you should be all good to go.
    No need to worry about problems, unless you change it from "ns1.google.com" to "non-exsiting"
    Don't worry Ma'am. We're university students, - We know what We're doing.
    'Ruiat coelum, fiat voluntas tua.'
    Datalogi - en livsstil; Intet liv, ingen stil.

  3. #3
    Newbie
    Join Date
    Jul 2008
    Location
    North-Central California USA
    Posts
    4

    changing hostname without fouling up network connection-- resolved

    Here's what I did:

    1. changed the content of /etc/hostname
    2. altered the 127.0.0.1 entry of /etc/hosts
    3. ran
    Code:
     #hostname <new_hostname>
    3. rebooted

    And it worked like a charm.

    Thanks for your help, redhead!

  4. #4
    Newbie
    Join Date
    Jul 2008
    Location
    North-Central California USA
    Posts
    4

    changing hostname with out fouling up network connection, follow-up

    Here are some entries from this morning's /var/log/boot I find interesting and would like the board's opinion about:
    Code:
    Tue Jul 22 04:32:04 2008: /dev/mapper/oldhostname-root: clean, 359383/9404416 files, 8092517/18795520 blocks
    Tue Jul 22 04:32:06 2008:   Found volume group "oldhostname" using metadata type lvm2
    Tue Jul 22 04:32:06 2008:   2 logical volume(s) in volume group "oldhostname" now active
    and likewise from this morning's # dmesg:
    Code:
    # dmesg
    Linux version 2.6.25.9 (root@oldhostname) (gcc version 4.3.1 (Debian 4.3.1-2) ) #1 SMP Fri Jul 4 19:52:20 PDT 2008
    Kernel command line: root=/dev/mapper/oldhostname-root ro
    Adding 2715640k swap on /dev/mapper/oldhostname]-swap_1.  Priority:-1 extents:1 across:2715640k
    Did I overlook some files to modify, or a command? Does it even matter? Will these incidences of oldhostname conflict somehow with newhostname and cause problems?

    Thank you for your time and expertise!

    Best regards from North-Central California USA,

    bezdomny

  5. #5
    Moderator
    Advisor
    redhead's Avatar
    Join Date
    Jun 2001
    Location
    Copenhagen, Denmark
    Posts
    811
    This has nothing todo with how hte machine is identified to the net, these messages has to do with the mapping of your harddrive and which machine name was active at the time when the kernel was created ie:
    Code:
    > dmesg|head -n 1
    Linux version 2.6.25 (root@fenris) (gcc version 4.1.2 20061115 (prerelease) (Debian 4.1.1-21)) #1 Sun Apr 20 11:42:41 CEST 2008
    > hostname
    garm
    So I build the kernel on a machine named "fenris" but have it running on a machine named "garm"
    Same thing with your info, the machine was named "oldhostname" when you created the install and build of kernel, so the mapping and kernel build info reflects that, the name in /etc/hostname and /etc/hosts is the one reflecting the machine towards the net it's a part of.
    Don't worry Ma'am. We're university students, - We know what We're doing.
    'Ruiat coelum, fiat voluntas tua.'
    Datalogi - en livsstil; Intet liv, ingen stil.

  6. #6
    Newbie
    Join Date
    Jul 2008
    Location
    North-Central California USA
    Posts
    4

    changing hostname with out fouling up network connection, solved & concluded

    Thank you as always, redhead. You've enlightened me and put my mind at ease. I think we're done now!

    best regards to all from North-Central California,

    bezdomny

Similar Threads

  1. Home network samba/hostname issue?
    By toddah in forum Linux - Hardware, Networking & Security
    Replies: 0
    Last Post: 09-08-2005, 07:39 PM
  2. ptp vpn connection and viewing network comptuers
    By cfutt in forum Windows - General Topics
    Replies: 6
    Last Post: 02-14-2005, 11:26 PM
  3. stop dhcp client changing hostname
    By skskal in forum Linux - Hardware, Networking & Security
    Replies: 2
    Last Post: 07-09-2004, 01:14 PM
  4. postgresql network connection
    By tomass in forum Linux - Hardware, Networking & Security
    Replies: 0
    Last Post: 04-26-2002, 04:24 PM
  5. changing hostname
    By agar in forum Linux - Hardware, Networking & Security
    Replies: 6
    Last Post: 12-04-2001, 09:31 AM

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •