Linux host name hostname setting in Linux is troublesome, and even modifying the host name is no exception. After Linux is installed, its default host name is localhost. Three steps are required to modify the Linux host name. Use hostname to modify the current host name. Hostnamenew-host... linux host name hostname setting in Linux is troublesome, even modifying
I found that the methods for changing the host's hostname in Linux are incomplete. The following is a complete method:
Step 00:
Assume that the original hostname is bkjia and you want to change it to bkjia03.
Use root to change the hostname
Su-rootStep 01:
Change bkjia in/etc/hosts to bkjia03
Vi/etc/hosts
:
127.0.0.1 bkjia03 localhost. localdomain localho
Issue 2: After modifying the hostname, how to make it effective immediately without restarting the operating system.Method 1: After you modify the hostname under/etc/sysconfig/network, then use echo servername >/proc/sys/kernel/hostname.[Email protected] ~]# echo Test >/proc/sys/kernel/hostnameNote that the current session still does not change, but subsequent ne
Linux system installed, there will be a default hostname, here in the case of the CentOS system, the default hostname is Localhost.localdomain, for ease of use, we often need to modify the hostname, the following is a way to permanently change the hostname.Steps:1. Log in as root, or switch to the root user after logging in, and then enter the
1. Modify the/etc/sysconfig/network configuration fileVi/etc/sysconfig/networkModify hostnameHostname=new-hostname.domainnameMy network changed to:Hostname=redhat5.xiaomu.com.2. Modify the local domain name resolution file/etc/hosts, so that the native application can resolve the new host name.Vi/etc/hostsWill 127.0.0.1 Localhost.localdomain localhostInstead: 127.0.0.1 new-hostname.domainname new-hostname mine is.127.0.0.1 redhat5.xiaomu.com redhat5 R
Recently, this problem occurs: when the customer configures the WCF Service, IIS is used as the HOST, but the customer does not purchase the website, so there is no resolution between the DNS and the IP address, only one IP address can be accessed from the external network, but the configured WCF Service on the server will look like this when it is released:
For example, if the Hostname of the IIS server is "ServerPC" and the IP address is "192.168.1
Reference Answer:View Host Name:HostnameTemporarily modify host Name:Hostname oldboyeduTo permanently modify the host name:/etc/sysconfig/networkAllow the hostname to be resolved (ping host name can be unblocked)IP address hostname put into/etc/hosts10.0.0.200 oldboyeduNoteToday is a day to accompany everyone's first day, look forward to your progress.For questions and answers, please leave a comment in th
Hostname changed under Linux gpdbStep 1, execute the vi/etc/sysconfig/network commandNetworking=yesHostname=gpdbSecond step, execute hostname gpdb orderStep three, execute the vi/etc/hosts command192.168.1.121 gpdb # Added by NetworkManager127.0.0.1 localhost.localdomain localhost:: 1 gpdb localhost6.localdomain6 Localhost6Step four, execute the reboot command again after you start the computer or use the S
Modified the hostname under/etc/sysconfig/network.
2. Use echo servername >/proc/sys/kernel/hostnameWhen the other terminal is opened, it will take effect immediately without restarting.Method 21. Modified the hostname under the/etc/sysconfig/network2. Then use the Sysctl kernel.hostname command to make it effective immediately[Email protected] ~]# sysctl Kernel.hostname=test2This article is from the "Aut
The CentOS 7 mini version of the default installation cannot use the Ifconfig command.
If it's not networked at this time, it's going to be bad.
First look at the Internet configuration of CentOS7Modify File/etc/sysconfig/network-scripts/ifcfg-enp0s3
The contents are as follows:
2014-10-12 00.25.18
OK, so you can surf the Internet.
Then install the ifconfig command to perform
Yum Install Net-tools
Modify hostname
Centos7 changes in the wa
In the Ubuntu system, there are several ways to quickly view the hostname:One, open a GNOME terminal window, you can see the host name at the command prompt, the hostname is usually after the "@" symbol;Second, enter the command in the terminal window: hostname or UNAME–N, you can view the host name of the current host.2. Temporarily modify host nameCommand line Run command: "
For some type of setups, if network connections not available during startup process, exim4 takes long time to start. To solve this problem, you must useDC_minimaldnsOption of exim4. you can also configure this feature
Dpkg-reconfigure exim4-config
On Debian based systems. You shoshould answerYesFor the question"Keep number of DNS-queries minimal?"
However, ifHostname -- fqdnCommand doesn't print a full qualified hostname (actually only checked one d
Question: Use a week Ubuntu14.04, feel oneself originally set the username and hostname is too long, want to modify.The result: One night passed, or a tragedy.Google search: Ubuntu modified the user name, looked at the first students in the article, according to the description to modify/etc/passwd and/etc/shadow, the old user name is modified to a new user name, after the completion of the modification to restart, and then the tragedy.Although the ne
MySQL 1042 Can't get hostname for your address Problem Analysis Solution Process [Comment 1] former colleague penguin said he installed mysql 5.5, found that when using the mysql client remote connection, the error 1042-Can't get hostname for your address is reported, but the permission has been granted and the grant is successful. This error indicates that "your address cannot obtain the host name", and I
[Comment 1]The former colleague penguin said that he installed MySQL 5.5 and reported the error 1042-can't get hostname for your address when using the mysql client for remote connection, however, the permission has been granted and the grant is successful.This error indicates that "your address cannot obtain the host name ".Skip-name-resolveParameters.
Official documentation:
--skip-name-resolveUse IP addresses rather than host names when creating gr
The solution is that you cannot connect to the linux host from XP to Win7 using the Linux hostname method. After the update, you want to connect to the Linux host saved by the original putty; originally, the access to the linux host was through the linux hostname method. This method was also used this time, But Win7 could not resolve this hostname. The DNS resolu
message 1Message 1:From [email protected] Wed Oct 26 14:14:46 2016Return-path: X-original-to:rootTS 0 0TMPFS/DEV/SHM TMPFS Defaults 0 0Devpts/dev/pts devpts gid=5,mode=620 0 0Sysfs/sys Sysfs Defaults 0 0PROC/PROC proc Defaults 0 0q Enter Q to exit the mail systemHeld 1 Message In/var/spool/mail/root9, hostname: Display host nameHostname Donggen indicates that the host name of the current host is changed to Donggen[Email protected] usr]# hostnameXueli
1, if only modify hostname can be by the following commandHostnameNote: This modification is only valid until the server restarts and the hostname expires, returning to the original hostname.2. If you need to permanently modify hostname, you can use the following commandModify the
The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion;
products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the
content of the page makes you feel confusing, please write us an email, we will handle the problem
within 5 days after receiving your email.
If you find any instances of plagiarism from the community, please send an email to:
info-contact@alibabacloud.com
and provide relevant evidence. A staff member will contact you within 5 working days.