?
Solved

Removing Samba

Posted on 2005-03-25
5
Medium Priority
?
478 Views
Last Modified: 2013-12-16
I have a web server that is running samba 2.0.9. I have tried to install newer versions. They all compile and install okay but when I check the version to make sure it installed it still states 2.0.9. I would like to remove samba and reinstall. Hopefully this will allow me to update version. Can some one tell me how to remove samba. Or what file to delete. Thanks.
0
Comment
Question by:jhawk3
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
5 Comments
 
LVL 15

Expert Comment

by:veedar
ID: 13632564
You don't say which Linux distro you are using. That would help.

But you can look in /etc/init.d/smb It will show you how samba gets started
Those are the files you need to update/change.
0
 
LVL 38

Accepted Solution

by:
wesly_chen earned 2000 total points
ID: 13633081
> remove samba and reinstall
As root,
for SuSE, use YasT to remove Samba,
for Fedora Core 2 or 3, use "system-config-package" to remove Samba (Windows File Server)
for RedHat or Fedora 1, use "redhat-config-package" to remove Samba (Windows File Server).

Or for all the RPM base Linux distribution, use
rpm -e `rpm -qa | grep -i samba`
to remove Samba.

If you compile from the source code, the newer version is usually install in /usr/local/bin/smbd.
So, as veedar suggested, you need to edit /etc/init.d/smb to reflect the path of newer version.

Wesly
0
 

Author Comment

by:jhawk3
ID: 13633362
The distro is on a Cobalt Qube 3 web server. It list as Cobalt Linux. I was install by source. I tried to upgrade to ver 3 of samba and it look like it went okay but still list version 2. What files should I redirect?
0
 
LVL 38

Expert Comment

by:wesly_chen
ID: 13633480
Cobalt Qube 3 is a special box for email/DNS/DHCP/FTP/Web/SAMBA server.
Most of the configuration/administration jobs use web interface. So it is better upgrade through BlueLink (?) instead of
compiling from the source code, otherwise, you miht break a lot of thing, specially the administration web interface links.

> upgrade to ver 3 of samba and it look like it went okay but still list version 2.
check which smbd you are running.
which smbd
smbd -V  # Check the version

I suspect you are still running samba 2 since you just install another version to different path.

Wesly

0
 
LVL 12

Expert Comment

by:GinEric
ID: 13639354
When you compile anything, like Samba, if you haven't simply removed the previous version with either pkgtool or something similar, you're symlinks and path remain unless you have set the proper environment variables during configure, make, and install.

Which means, the OS continues to revert to the officially installed package, the original.

Most recent programs are no longer installing control to /etc rather to /usr/local/Samba/etc and the like.

So your OS is still accessing the old path.

You've got more than one problem because even running smbd from /etc is not going to run the new Samba.

Unfortunately, there is no quick fix currently.  Editing configure and the environment is only valid if the previous Samba is removed and you set the proper paths:

Example: Typical configure from MySQL5.0.2 -  a one meg configure script:

bindir='${exec_prefix}/bin'
sbindir='${exec_prefix}/sbin'
libexecdir='${exec_prefix}/libexec'
datadir='${prefix}/share'
sysconfdir='${prefix}/etc'
sharedstatedir='${prefix}/com'
localstatedir='${prefix}/var'
libdir='${exec_prefix}/lib'
includedir='${prefix}/include'
oldincludedir='/usr/include'
infodir='${prefix}/info'
mandir='${prefix}/man'

My writeups on this problem are here:

http://www.musics.com/docs/UNCLE/index.html

and here:

http://www.musics.com/manhtml/New/Configure/ConfigureNew.html

Basically, you want to use the export command properly from within configure; something not always so easy to do.

You can see above that if the prefix "/usr" is used, then the executables to to "/usr/etc" instead of to "/etc" and therein lies the problem.

What I have proposed is to replace a "per configure script" string of definiions with a selectible LAYOUT option similar to what Apache uses, but using files instead of script configures to set the paths, etc..

You must remember that if you try to compile and then install Samba, or any other program, while it is running or without removing and cleaning first, there is the possibility that the new installation will break the old and result in both being broken.

You have to "redirect" all files, but you have to first remove the first Samba package.  I am not aware that you can "update" any program and this is because most don't allow the symlinks to be installed automatically.  So the catch-22 is that you may lose all your users in the Samba config, unless somehow you figure out how to keep a copy and replace it for the new version.

Find your install directories from the general Apache layout file.  Apache seems to have been the only developer on top of this, I can't find any others who have given enough attention to this problem.
0

Featured Post

Linux Academy Android App Now Supports Chromecast

We have some fantastic news for our Android fans. We’re so excited to announce that the Linux Academy Android app is now available with Chromecast support. That’s right – simply download the latest update of the Linux Academy App and start casting your favorite course videos!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Fine Tune your automatic Updates for Ubuntu / Debian
In part one, we reviewed the prerequisites required for installing SQL Server vNext. In this part we will explore how to install Microsoft's SQL Server on Ubuntu 16.04.
Connecting to an Amazon Linux EC2 Instance from Windows Using PuTTY.
How to Install VMware Tools in Red Hat Enterprise Linux 6.4 (RHEL 6.4) Step-by-Step Tutorial
Suggested Courses
Course of the Month8 days, 8 hours left to enroll

764 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question