setting up snmpd on MAC Server OS X via ssh verify /usr/sbin/snmpd exists ls /usr/sbin/snmpd verify /usr/share/snmp/snmpd.conf exists ls /usr/share/snmp/snmpd.conf if snmpd.conf doesn't exist, run: /usr/bin/snmpconf -i (-i is required to write the file to the correct location) set the following options: default = all 1 (snmpd.conf) 1 (access control setup) 3 v1/2c ro community name <ro_community> f 4 (Agent operating mode) 2 (system user agent runs as) root f 5 (system information setup) 1 (physical location of system) <system_location> f 6 (trap destinations) 2 (v2c trap receiver) <monitoring_system_ipaddr> [ENTER] [ENTER] 3 (v2c inform receiver) <monitoring_system_ipaddr> [ENTER] [ENTER] 5 (default trap sink community) <ro_community> f f q starting snmpd: /usr/sbin/snmpd restart snmpd: kill -HUP <pid> finally, to make sure it runs at boot time: ======================================================================================= from: http://scott.wallace.sh/2009/12/04/enabling-snmp-in-mac-os-x-10-6-snow-leopard/ --------------------------------------------------------------------------------------- Under Snow Leopard there is a slight change to the way services are enabled. -w Overrides the Disabled key and sets it to false. In previous versions, this option would modify the configuration file. Now the state of the Disabled key is stored elsewhere on-disk. So, to enable the SNMP daemon correctly: $ sudo launchctl load -w /System/Library/LaunchDaemons/org.net-snmp.snmpd.plist =======================================================================================
Friday, May 27, 2011
Setting up SNMP on OSX 10 Xserve via SSH
Monday, May 23, 2011
Configuring DNS Servers on OS X via SSH
Need to set up/change the DNS servers on a Mac OS X system, using SSH. Command to use is networksetup. For instance:
$ networksetup /?
for all it's gory details.
What concerns me today is just DNS config for the system. So, without further adiou, commands are in bold:
user:~ localhost$ networksetup -listallnetworkservices
An asterisk (*) denotes that a network service is disabled.
Ethernet 1
Ethernet 2
*Built-in Serial Port (1)
FireWire
user:~ localhost$ networksetup -getdnsservers Ethernet\ 1 (observe your character escape sequences)
192.168.1.10
192.168.1.9
user:~ localhost$ networksetup -getdnsservers Ethernet\ 2
192.168.1.10
192.168.1.9
user:~ localhost$ sudo networksetup -setdnsservers Ethernet\ 1 10.75.66.2
Password:
user:~ localhost$ networksetup -getdnsservers Ethernet\ 1
10.75.66.2
user:~ localhost$ sudo networksetup -setdnsservers Ethernet\ 2 10.75.66.2
user:~ localhost$ networksetup -getdnsservers Ethernet\ 2
10.75.66.2
user:~ localhost$
$ networksetup /?
for all it's gory details.
What concerns me today is just DNS config for the system. So, without further adiou, commands are in bold:
user:~ localhost$ networksetup -listallnetworkservices
An asterisk (*) denotes that a network service is disabled.
Ethernet 1
Ethernet 2
*Built-in Serial Port (1)
FireWire
user:~ localhost$ networksetup -getdnsservers Ethernet\ 1 (observe your character escape sequences)
192.168.1.10
192.168.1.9
user:~ localhost$ networksetup -getdnsservers Ethernet\ 2
192.168.1.10
192.168.1.9
user:~ localhost$ sudo networksetup -setdnsservers Ethernet\ 1 10.75.66.2
Password:
user:~ localhost$ networksetup -getdnsservers Ethernet\ 1
10.75.66.2
user:~ localhost$ sudo networksetup -setdnsservers Ethernet\ 2 10.75.66.2
user:~ localhost$ networksetup -getdnsservers Ethernet\ 2
10.75.66.2
user:~ localhost$
Friday, May 20, 2011
Making X work on RHEL/CEntOS 5 after VMWare P2V Import
Used the VMWare Standalone Converter running on my local machine to import a RHEL/CEntOS 5 Linux system, and afterward, was greeted with the following (this is cli, the gui had it's own errors):
-----snip-----
[root@qa01 ~]# startx
xauth: creating new authority file /root/.serverauth.9175
xauth: creating new authority file /root/.Xauthority
xauth: creating new authority file /root/.Xauthority
X Window System Version 7.1.1
Release Date: 12 May 2006
X Protocol Version 11, Revision 0, Release 7.1.1
Build Operating System: Linux 2.6.18-164.6.1.el5 x86_64 Red Hat, Inc.
Current Operating System: Linux qa01.localdomain 2.6.18-164.11.1.el5 #1 SMP Wed Jan 6 13:26:04 EST 2010 x86_64
Build Date: 16 November 2009
Build ID: xorg-x11-server 1.1.1-48.67.el5_4.1
Before reporting problems, check http://wiki.x.org
to make sure that you have the latest version.
Module Loader present
Markers: (--) probed, (**) from config file, (==) default setting,
(++) from command line, (!!) notice, (II) informational,
(WW) warning, (EE) error, (NI) not implemented, (??) unknown.
(==) Log file: "/var/log/Xorg.0.log", Time: Fri May 20 12:28:27 2011
(==) Using config file: "/etc/X11/xorg.conf"
(EE) No devices detected.
Fatal server error:
no screens found
XIO: fatal IO error 104 (Connection reset by peer) on X server ":0.0"
after 0 requests (0 known processed) with 0 events remaining.
[root@qa01 ~]#
-----snip-----
Some digging online led me to http://www.vmware.com/pdf/osp_install_guide.pdf
I realize it probably makes more sense to add the yum repo, but since I was in a hurry, I just pulled the files manually and did a local install. The files I needed are listed below:
Files are located at: http://packages.vmware.com/tools/esx/4.1/rhel5/x86_64/
IMPORTANT!!! BUILD NUMBERS ARE CRITICAL!!!
Make sure you get the build number for your version of VMWare and Guest OS
vmware-tools-nox-8.3.2-257589.el5.x86_64.rpm
vmware-tools-8.3.2-257589.el5.x86_64.rpm
vmware-tools-common-8.3.2-257589.el5.x86_64.rpm
vmware-open-vm-tools-8.3.2-257589.el5.x86_64.rpm
vmware-open-vm-tools-common-8.3.2-257589.el5.x86_64.rpm
vmware-open-vm-tools-nox-8.3.2-257589.el5.x86_64.rpm
vmware-open-vm-tools-xorg-utilities-8.3.2-257589.el5.x86_64.rpm
vmware-open-vm-tools-kmod-8.3.2-257589.el5.x86_64.rpm
vmware-open-vm-tools-xorg-drv-mouse-12.6.4.0-0.257589.el5.x86_64.rpm
vmware-open-vm-tools-xorg-drv-display-10.16.7.0-0.257589.el5.x86_64.rpm
Commands as follows:
wget http://packages.vmware.com/tools/esx/4.1/rhel5/x86_64/<package_name>
(yes, this has to be done for each rpm)
wget http://packages.vmware.com/tools/keys/VMWARE-PACKAGING-GPG-RSA-KEY.pub
rpm --import VMWARE-PACKAGING-GPG-RSA-KEY.pub (this saves you from the --no-gpg-check)
yum localinstall <big_list_of_all_rpms_use_tab_complete>
So, now that you're done with all that, it's time to reboot. Yes, this is needed (remember that kmod rpm you just installed?). After the reboot, everything works with X just fine.
And now things work virtually like they did before. (=
-----snip-----
[root@qa01 ~]# startx
xauth: creating new authority file /root/.serverauth.9175
xauth: creating new authority file /root/.Xauthority
xauth: creating new authority file /root/.Xauthority
X Window System Version 7.1.1
Release Date: 12 May 2006
X Protocol Version 11, Revision 0, Release 7.1.1
Build Operating System: Linux 2.6.18-164.6.1.el5 x86_64 Red Hat, Inc.
Current Operating System: Linux qa01.localdomain 2.6.18-164.11.1.el5 #1 SMP Wed Jan 6 13:26:04 EST 2010 x86_64
Build Date: 16 November 2009
Build ID: xorg-x11-server 1.1.1-48.67.el5_4.1
Before reporting problems, check http://wiki.x.org
to make sure that you have the latest version.
Module Loader present
Markers: (--) probed, (**) from config file, (==) default setting,
(++) from command line, (!!) notice, (II) informational,
(WW) warning, (EE) error, (NI) not implemented, (??) unknown.
(==) Log file: "/var/log/Xorg.0.log", Time: Fri May 20 12:28:27 2011
(==) Using config file: "/etc/X11/xorg.conf"
(EE) No devices detected.
Fatal server error:
no screens found
XIO: fatal IO error 104 (Connection reset by peer) on X server ":0.0"
after 0 requests (0 known processed) with 0 events remaining.
[root@qa01 ~]#
-----snip-----
Some digging online led me to http://www.vmware.com/pdf/osp_install_guide.pdf
I realize it probably makes more sense to add the yum repo, but since I was in a hurry, I just pulled the files manually and did a local install. The files I needed are listed below:
Files are located at: http://packages.vmware.com/tools/esx/4.1/rhel5/x86_64/
IMPORTANT!!! BUILD NUMBERS ARE CRITICAL!!!
Make sure you get the build number for your version of VMWare and Guest OS
vmware-tools-nox-8.3.2-257589.el5.x86_64.rpm
vmware-tools-8.3.2-257589.el5.x86_64.rpm
vmware-tools-common-8.3.2-257589.el5.x86_64.rpm
vmware-open-vm-tools-8.3.2-257589.el5.x86_64.rpm
vmware-open-vm-tools-common-8.3.2-257589.el5.x86_64.rpm
vmware-open-vm-tools-nox-8.3.2-257589.el5.x86_64.rpm
vmware-open-vm-tools-xorg-utilities-8.3.2-257589.el5.x86_64.rpm
vmware-open-vm-tools-kmod-8.3.2-257589.el5.x86_64.rpm
vmware-open-vm-tools-xorg-drv-mouse-12.6.4.0-0.257589.el5.x86_64.rpm
vmware-open-vm-tools-xorg-drv-display-10.16.7.0-0.257589.el5.x86_64.rpm
Commands as follows:
wget http://packages.vmware.com/tools/esx/4.1/rhel5/x86_64/<package_name>
(yes, this has to be done for each rpm)
wget http://packages.vmware.com/tools/keys/VMWARE-PACKAGING-GPG-RSA-KEY.pub
rpm --import VMWARE-PACKAGING-GPG-RSA-KEY.pub (this saves you from the --no-gpg-check)
yum localinstall <big_list_of_all_rpms_use_tab_complete>
So, now that you're done with all that, it's time to reboot. Yes, this is needed (remember that kmod rpm you just installed?). After the reboot, everything works with X just fine.
And now things work virtually like they did before. (=
Subscribe to:
Posts (Atom)