Many users who have installed RHEL with virtual machines may encounter this problem: when you want to view the status of a service (such as samba), [root@www.linuxidc.com ~] # Servicesmbstatussmb: unrecognizedservice. Therefore
Many users who have installed RHEL on a virtual machine may encounter this problem: when you want to view the status of a service (such as samba ),
[Root @ www.linuxidc.com ~] # Service smb status
Smb: unrecognized service
You will be surprised to find that the system prompts: smb: unrecognized service. At this time, you will check whether samba has been installed as usual. ThereforeRpm-qa | grep sambaThe following result is returned:
[Root @ www.linuxidc.com ~] # Rpm-qa | grep samba
Samba-client-3.0.33-3.28-1. el5
Samba-common-3.0.33-3.28-1. el5
By the way, the basic software package required to build a samba server is as follows:
1. samba --> This package contains the main daemon files (smbd and nmbd)
2. samba-common --> provides the main configuration files (smb. conf) and smb. conf syntax check programs (testparm) of samba.
3. samba-client --> when linux acts as the samba client, it provides a set of required tools and commands.
Now we can see that the samba main program has not been installed, so now we can find the samba rpm package in the iso image.
First mount the iso image,The device ID of the optical drive is/dev/hdc.,
[Root @ www.linuxidc.com ~] # Mkdir/mnt/temp
[Root @ www.linuxidc.com ~] # Mount/dev/hdc/mnt/temp
[Root @ www.linuxidc.com ~] # Ll/mnt/temp/Server | grep samba
Samba-3.0.33-3.28-1. el5. I386. Rpm
Samba-common-3.0.33-3.28-1. el5. I386. Rpm
Samba-client-3.0.33-3.28-1. el5.i386. Rpm
...
[Root @ www.linuxidc.com ~] # Rpm-ivh/Mnt/temp/Server/Samba-3.0.33-3.28-1. el5. I386. Rpm
Error: Failed dependencies:
Perl (Convert: ASN1) is neededSamba-3.0.33-3.28-1. el5. I386
An error is reported. The perl ASN1 package is missing.
Solution: InstallPerl-Convert-ASN1-0.20-1.1.noarch.rpm
[Root @ www.linuxidc.com ~] # Rpm-ivh/Mnt/temp/Server/Perl-Convert-ASN1-0.20-1.1.noarch.rpm
After the installation is successful [Root @ www.linuxidc.com ~] # Rpm-ivh/Mnt/temp/Server/Samba-3.0.33-3.28-1. el5. I386. Rpm
Then samba can be installed normally. Check the results:
[Root @ www.linuxidc.com ~] # Service smb status
Smbd is stopped
Nmbd is stopped
There is no prompt like smb: unrecognized service.
PS: here the system is rhel-server-5.5-i386, the specific version of the software may be different from yours.