Hi,
I am trying to list those services which run in ESX 4. If I use chkconfig I get a 'command not recognised'. I can use ps aux and top but cannot see the services that I would expect i.e.
mgmt-vmware
vmware-vpxa
vmware-vmkauthd
vmware-webAccess
sshd
snmpd
vmware-aam
wsman
I need to see if two services are running, active x and java. I can see a java listed under ps aux but no active x. However if I try to restart java using service java restart I get bash service command not found.
Is there another command I should be using, please advise?
Thanks
Hi,
You got the path of service. so run /etc/vmware/service --status-all or /sbin/service --status-all
it should work
Regards
Senthil Kumar D
Hi,
Please use below command.
service --status-all
if seems usefull assign points.
thanx
Hi,
Thanks for the response but I'm getting a 'command not found'
Is that syntax spot on?
Thanks
type proper syntax.there is one space between service and hyphen before status and no any space between status and all.
also 2 hyphens before status and 1 hyphen before all.
so
service(space)--status-all
service --status-all
Still getting the command not found message.
I login with a standard user I have created and then use the su command
I then use the service --status-all
Do I need to be in a particular folder/directory as a specific user?
Cheers
screen grab below. You are running ESX classic, not ESXi, correct?
root@ESX4~# service --status-all crond (pid 2391) is running... Chain INPUT (policy ACCEPT 36M packets, 14G bytes) pkts bytes target prot opt in out source destination Chain FORWARD (policy DROP 0 packets, 0 bytes) pkts bytes target prot opt in out source destination Chain OUTPUT (policy ACCEPT 8193K packets, 4019M bytes) pkts bytes target prot opt in out source destination Neither incoming nor outgoing blocked by default Enabled services: CIMSLP ntpClient aam VCB CIMHttpsServer sshClient vpxHeartbeats ftpClient CIMHttpServer snmpd faultTolerance sshServer Opened ports: Syslog : port 514 udp.out sim-cert : port 280 tcp.out hpim : port 2381 tcp.in Added Iprules: Firewall is stopped. Table: filter Chain INPUT (policy ACCEPT) num target prot opt source destination Chain FORWARD (policy DROP) num target prot opt source destination Chain OUTPUT (policy ACCEPT) num target prot opt source destination krb524d is stopped mcstransd is stopped vmware-hostd (pid 2467) is running... netconsole module not loaded netplugd is stopped Configured devices: lo vswif0 Currently active devices: lo vmnic0 vmnic1 vmnic2 vmnic3 vmnic4 vmnic5 vswif0 rpc.mountd is stopped nfsd is stopped rpc.statd is stopped nscd is stopped ntpd (pid 2245) is running... portmap is stopped Process accounting is disabled. rdisc is stopped rpc.idmapd (pid 2065) is running... sfcbd is running running slpd is running snmpd is stopped snmptrapd is stopped sshd (pid 3852 2200) is running... syslogd (pid 2017) is running... klogd (pid 2020) is running... Usage: (halt|reboot|start) {start} Usage: vmware {start|stop|status} vmware-aam is running [ OK ] Usage: vmware-autostart {start|stop|restart} none VMware VMkernel authorization daemon is running (pid 2408). vmware-vpxa is running webAccess is stopped winbindd is stopped openwsmand is running xinetd (pid 2221) is running... ypbind is stopped
or
[root@ESX4 ~]# chkconfig --list
run both as root
Hi Troy,
I can see you have it working. I am using putty to get on the console remotely. Yes it is ESX and not ESXi.
The user I login as seem to default to /home/sshuser this might be the cause....
I'm guessing I need to login as the root and not an alternative and then using the su command?
Thanks again
Simon
su to root and then run either command posted above and you will see your results returned.
Hi,
I think PATH problem. can you try # /usr/sbin/service --status-all
Regards
Senthil Kumar D
Hi,
This is what I receive:
login as: sshuser
sshuser@192.168.1.241's password:
Last login: Mon Mar 15 14:22:38 2010 from 192.168.1.201
Password:
bash: service: command not found
bash: service: command not found
# /usr/sbin/service --status-all
bash: /usr/sbin/service: No such file or directory
# cd /usr/sbin/service --status-all
bash: cd: /usr/sbin/service: No such file or directory
bash: service: command not found
Thanks again
HI,
please find the path of the service using find command.
find / -name service
if find command not working give output of $PATH
Regards
Senthil Kumar D
This is what I get:
login as: sshuser
sshuser@192.168.1.241's password:
Last login: Mon Mar 15 14:22:38 2010 from 192.168.1.201
Password:
bash: service: command not found
bash: service: command not found
# /usr/sbin/service --status-all
bash: /usr/sbin/service: No such file or directory
# cd /usr/sbin/service --status-all
bash: cd: /usr/sbin/service: No such file or directory
bash: service: command not found
/etc/vmware/service
/sbin/service
bash: service: command not found
bash: service: command not found
Hi,
You got the path of service. so run /etc/vmware/service --status-all or /sbin/service --status-all
it should work
Regards
Senthil Kumar D
HI
Senthil is right, it should work, but just to clear up, you need to use the command /sbin/service --status-all
/etc/vmware/service is actually a directory and won't work... 😃
😃
It works!!!
Thanks for all your help guys
Thank you Senthil
Simon