安装samba实现共享文件夹时遇到的一些依赖关系问题(ubuntu1204)



//----------------------------------------------------------------------------------------------------------------
sudo apt-get install samba
遇到依赖关系,下面2个版本冲突
samba-common
libwbclient0


//----------------------------------------------------------------------------------------------------------------
xcz@xcz-OptiPlex-3020:~/Desktop$ 
xcz@xcz-OptiPlex-3020:~/Desktop$ sudo apt-get remove samba
Reading package lists... Done
Building dependency tree       
Reading state information... Done
Package samba is not installed, so not removed
0 upgraded, 0 newly installed, 0 to remove and 0 not upgraded.


//----------------------------------------------------------------------------------------------------------------
xcz@xcz-OptiPlex-3020:~/Desktop$ 
xcz@xcz-OptiPlex-3020:~/Desktop$ sudo apt-get remove libwbclient0
Reading package lists... Done
Building dependency tree       
Reading state information... Done
The following packages were automatically installed and are no longer required:
  apturl-common apturl
Use 'apt-get autoremove' to remove them.
The following packages will be REMOVED:
  gvfs-backends libsmbclient libwbclient0 nautilus-share python-smbc
  samba-common-bin smbclient system-config-printer-common
  system-config-printer-gnome ubuntu-desktop
0 upgraded, 0 newly installed, 10 to remove and 0 not upgraded.
After this operation, 72.5 MB disk space will be freed.
Do you want to continue [Y/n]? 
--》Y


//----------------------------------------------------------------------------------------------------------------
xcz@xcz-OptiPlex-3020:~/Desktop$ 
xcz@xcz-OptiPlex-3020:~/Desktop$ sudo apt-get remove samba-common
Reading package lists... Done
Building dependency tree       
Reading state information... Done
The following packages were automatically installed and are no longer required:
  libtalloc2 python-cupshelpers libcdio-paranoia1 python-gnomekeyring
  apturl-common avahi-utils system-config-printer-udev apturl libcdio-cdda1
Use 'apt-get autoremove' to remove them.
The following packages will be REMOVED:
  samba-common
0 upgraded, 0 newly installed, 1 to remove and 0 not upgraded.
After this operation, 682 kB disk space will be freed.
Do you want to continue [Y/n]? y
(Reading database ... 162670 files and directories currently installed.)
Removing samba-common ...
xcz@xcz-OptiPlex-3020:~/Desktop$ 
xcz@xcz-OptiPlex-3020:~/Desktop$ 
xcz@xcz-OptiPlex-3020:~/Desktop$ 


//----------------------------------------------------------------------------------------------------------------
xcz@xcz-OptiPlex-3020:~/Desktop$ 
xcz@xcz-OptiPlex-3020:~/Desktop$ sudo apt-get install samba samba-common system-config-samba winbind 
Reading package lists... Done
Building dependency tree       
Reading state information... Done
The following packages were automatically installed and are no longer required:
  python-cupshelpers libcdio-paranoia1 python-gnomekeyring apturl-common
  avahi-utils system-config-printer-udev apturl libcdio-cdda1
Use 'apt-get autoremove' to remove them.
The following extra packages will be installed:
  libpam-winbind libuser1 libwbclient0 python-central python-libuser
  samba-common-bin tdb-tools
Suggested packages:
  openbsd-inetd inet-superserver smbldap-tools ldb-tools ctdb
The following NEW packages will be installed:
  libpam-winbind libuser1 libwbclient0 python-central python-libuser samba
  samba-common samba-common-bin system-config-samba tdb-tools winbind
0 upgraded, 11 newly installed, 0 to remove and 0 not upgraded.
Need to get 25.2 MB of archives.
After this operation, 62.8 MB of addi


//----------------------------------------------------------------------------------------------------------------
之后发现
smb://xxx.xx.x.XXX/ 访问不了
并且ubuntu-desktop被卸掉了,现在再恢复回去
//----------------------------------------------------------------------------------------------------------------
The following packages will be REMOVED:
  gvfs-backends libsmbclient libwbclient0 nautilus-share python-smbc
  samba-common-bin smbclient system-config-printer-common
  system-config-printer-gnome ubuntu-desktop
0 upgraded, 0 newly installed, 10 to remove and 0 not upgraded.




The following NEW packages will be installed:
  libpam-winbind--- libuser1 libwbclient0 python-central python-libuser samba---
  samba-common---- samba-common-bin--- system-config-samba----- tdb-tools winbind-----
0 upgraded, 11 newly installed, 0 to remove and 0 not upgraded.


//------------------------------------------------------------------------------------remove
把安装的都卸掉(截的片段,仅参考)


The following NEW packages will be installed:
   libuser1 libwbclient0 python-central python-libuser
    tdb-tools
0 upgraded, 11 newly installed, 0 to remove and 0 not upgraded.


//-------------------------------------------1
xcz@xcz-OptiPlex-3020:~/Desktop$ sudo apt-get remove samba samba-common system-config-samba winbind 
Reading package lists... Done
Building dependency tree       
Reading state information... Done
The following packages were automatically installed and are no longer required:
  libtalloc2 python-cupshelpers libcdio-paranoia1 libwbclient0 python-central
  python-gnomekeyring apturl-common tdb-tools avahi-utils
  system-config-printer-udev libuser1 apturl libcdio-cdda1 python-libuser
Use 'apt-get autoremove' to remove them.
The following packages will be REMOVED:
  libpam-winbind samba samba-common samba-common-bin system-config-samba
  winbind
0 upgraded, 0 newly installed, 6 to remove and 0 not upgraded.
After this operation, 61.9 MB disk space will be freed.
Do you want to continue [Y/n]? 


//----------------------------------------2
The following packages were automatically installed and are no longer required:
  libtalloc2 python-cupshelpers libcdio-paranoia1 python-gnomekeyring
  apturl-common avahi-utils system-config-printer-udev apturl libcdio-cdda1
Use 'apt-get autoremove' to remove them.
The following packages will be REMOVED:
  libuser1 libwbclient0 python-central python-libuser tdb-tools
0 upgraded, 0 newly installed, 5 to remove and 0 not upgraded.
After this operation, 903 kB disk space will be freed.
Do you want to continue [Y/n]? 


//---------------------------------------------------------------------remove --end


//----------------------------------------------------------------------------------------------------------------
下面再把原来remove掉的装回来(截的片段,仅参考)


The following packages will be REMOVED:
  gvfs-backends libsmbclient libwbclient0 nautilus-share python-smbc
  samba-common-bin smbclient system-config-printer-common
  system-config-printer-gnome ubuntu-desktop
0 upgraded, 0 newly installed, 10 to remove and 0 not upgraded.


The following packages will be REMOVED:
  gvfs-backends libsmbclient----- libwbclient0---- nautilus-share--- python-smbc---
  samba-common-bin--- smbclient--- system-config-printer-common-----
  system-config-printer-gnome---- ubuntu-desktop----
0 upgraded, 0 newly installed, 10 to remove and 0 not upgraded.


sudo apt-get install libwbclient0


The following NEW packages will be installed:
  nautilus-share samba-common samba-common-bin


The following NEW packages will be installed:
  python-smbc system-config-printer-common




The following extra packages will be installed:
  linux-headers-3.2.0-23 linux-headers-3.2.0-23-generic linux-headers-generic
The following NEW packages will be installed:
  linux-headers-3.2.0-23 linux-headers-3.2.0-23-generic linux-headers-generic
  ubuntu-desktop
0 upgraded, 4 newly installed, 0 to remove and 0 not upgraded.
Need to get 12.4 MB of archives.
|
|
|
sudo apt-get install gvfs-backends
The following packages have unmet dependencies:
 gvfs-backends : Depends: gvfs (= 1.12.1-0ubuntu1) but 1.12.1-0ubuntu1.2 is to be installed
                 Depends: gvfs-daemons (= 1.12.1-0ubuntu1)
                 Depends: gvfs-libs (= 1.12.1-0ubuntu1) but 1.12.1-0ubuntu1.2 is to be installed
                 Depends: gvfs-common (= 1.12.1-0ubuntu1) but 1.12.1-0ubuntu1.2 is to be installed
E: Unable to correct problems, you have held broken packages.
|
|
|
xcz@xcz-OptiPlex-3020:~$ 
xcz@xcz-OptiPlex-3020:~$ sudo aptitude install gvfs-backends
The following NEW packages will be installed:
  gvfs-backends{b} 
0 packages upgraded, 1 newly installed, 0 to remove and 0 not upgraded.
Need to get 1,012 kB of archives. After unpacking 2,877 kB will be used.
The following packages have unmet dependencies:
 gvfs-backends : Depends: gvfs (= 1.12.1-0ubuntu1) but 1.12.1-0ubuntu1.2 is installed.
                 Depends: gvfs-daemons (= 1.12.1-0ubuntu1) but 1.12.1-0ubuntu1.2 is installed.
                 Depends: gvfs-libs (= 1.12.1-0ubuntu1) but 1.12.1-0ubuntu1.2 is installed.
                 Depends: gvfs-common (= 1.12.1-0ubuntu1) but 1.12.1-0ubuntu1.2 is installed.
The following actions will resolve these dependencies:


     Remove the following packages:                       
1)     unity-launcher-folders                             


     Keep the following packages at their current version:
2)     gvfs-backends [Not Installed]                      






Accept this solution? [Y/n/q/?] 
||
||
||
choose Y and remove unity-launcher-folders ==>Unity 橱窗 这个软件本来就是ubuntu-1404上的,有依赖问题,后来一直没删
||
sudo aptitude install gvfs-backends


     Keep the following packages at their current version:
2)     gvfs-backends [Not Installed]  
Accept this solution? [Y/n/q/?] 
||
choose N and then choose Y to upgrade the version of depends packages






//----------------------------------------------------------------------------------------------------------------
sudo apt-get install samba
==>ok


//----------------------------------------------------------------------------------------------------------------
要共享的文件夹-->右击-->Proprerties-->Share
-->勾选下面三个选项
(1)Share this folder
(2)Allow others to create and delete ...
(3)Guest access


//----------------------------------------------------------------------------------------------------------------

ok,别人可以访问你的共享文件夹了


评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值