12-05-2009
there is only one hostname. it's the name inside /etc/nodename.
10 More Discussions You Might Find Interesting
1. UNIX for Dummies Questions & Answers
Hi !
Does anyone know how can i get information about my network interface ... if it works in half or full duplex mode !!
Thx in adivance !
Witt (4 Replies)
Discussion started by: witt
4 Replies
2. Solaris
I recently brought up a second network interface adapter in my Solaris 8 box. I configured the /etc/hostname.interface (hostname.ce1 in this case) with the hostname of the new adapter. I then added that hostname to the /etc/hosts file. Problem is when I reboot the ce1 interface is plumbed, but... (1 Reply)
Discussion started by: ghuber
1 Replies
3. Linux
Hello everybody,
How can link network interface to the output of lspci -vv. Basicly i need to know who is the manufacturer of a specific interface, for example eth0 {Is it an Intel, or Broadcome, or something else}. Is there a way to find that out?
Thanx (5 Replies)
Discussion started by: aleksey
5 Replies
4. Solaris
Hi.. Every one,
I have servers installed with solaris 10.We have configured our servers for IPMP and we have respective entries in /etc/hostname.<interface> for every physical interface.
for example one of the file contains :
# more /etc/hostname.ce6
super-ce6 netmask + broadcast + group... (3 Replies)
Discussion started by: Reboot
3 Replies
5. Solaris
i need to configure a zone to use different interface (bge2) than global and have connected to completely different network switch & to use its own defaultrouter and hosts file .. is it possible ..if so ..how ?
Thanks (9 Replies)
Discussion started by: skamal4u
9 Replies
6. UNIX and Linux Applications
Hi,
I'm a italian student. For my thesis I develop a gateway with protocol 6lowpan.
For that I must access to network interface to develope my personal stack based on standard 802.15.4.
Can you help me? I need an explanation for that. (0 Replies)
Discussion started by: berny88
0 Replies
7. IP Networking
Hello,
Please what's the difference between:
AND
Thank you so much (3 Replies)
Discussion started by: chercheur857
3 Replies
8. IP Networking
Hello,
Please, how can i create a network interface with a routable IP address on linux (ubuntu) ?
AND
How can i desactivate an interface?
Thank you so much for help. (1 Reply)
Discussion started by: chercheur857
1 Replies
9. Solaris
I've one Netra 240
After changing main board and system configuration card reader, Network is not accessible any more, Network interfaces are always UP and Running even when there is no cable connected to Network interfaces.
I tried to restart and plumb/unplumb with no luck.
ifconfig -a... (7 Replies)
Discussion started by: samer.odeh
7 Replies
10. UNIX for Dummies Questions & Answers
I have a RHEL 5 system with a bonded interface configure using only one network port (eth0). So I have config file for ifcfg-bond0 and ifcfg-eth. I'd like to configure eth5 to be the second SLAVE in the bond. My question is, after I modify ifcfg-eth5, can I add eth5 to the bond0 interface without... (1 Reply)
Discussion started by: westmoreland
1 Replies
UNAME(2) Linux Programmer's Manual UNAME(2)
NAME
uname - get name and information about current kernel
SYNOPSIS
#include <sys/utsname.h>
int uname(struct utsname *buf);
DESCRIPTION
uname returns system information in the structure pointed to by buf. The utsname struct is defined in <sys/utsname.h>:
struct utsname {
char sysname[];
char nodename[];
char release[];
char version[];
char machine[];
#ifdef _GNU_SOURCE
char domainname[];
#endif
};
The length of the arrays in a struct utsname is unspecified; the fields are NUL-terminated.
RETURN VALUE
On success, zero is returned. On error, -1 is returned, and errno is set appropriately.
ERRORS
EFAULT buf is not valid.
CONFORMING TO
SVr4, SVID, POSIX, X/OPEN. There is no uname call in BSD 4.3.
The domainname member (the NIS or YP domain name) is a GNU extension.
NOTES
This is a system call, and the operating system presumably knows its name, release and version. It also knows what hardware it runs on.
So, four of the fields of the struct are meaningful. On the other hand, the field nodename is meaningless: it gives the name of the
present machine in some undefined network, but typically machines are in more than one network and have several names. Moreover, the kernel
has no way of knowing about such things, so it has to be told what to answer here. The same holds for the additional domainname field.
To this end Linux uses the system calls sethostname(2) and setdomainname(2). Note that there is no standard that says that the hostname
set by sethostname(2) is the same string as the nodename field of the struct returned by uname (indeed, some systems allow a 256-byte host-
name and an 8-byte nodename), but this is true on Linux. The same holds for setdomainname(2) and the domainname field.
The length of the fields in the struct varies. Some operating systems or libraries use a hardcoded 9 or 33 or 65 or 257. Other systems use
SYS_NMLN or _SYS_NMLN or UTSLEN or _UTSNAME_LENGTH. Clearly, it is a bad idea to use any of these constants - just use sizeof(...). Often
257 is chosen in order to have room for an internet hostname.
There have been three Linux system calls uname(). The first one used length 9, the second one used 65, the third one also uses 65 but adds
the domainname field.
Part of the utsname information is also accessible via sysctl and via /proc/sys/kernel/{ostype, hostname, osrelease, version, domainname}.
SEE ALSO
uname(1), getdomainname(2), gethostname(2)
Linux 2.5.0 2001-12-15 UNAME(2)