Vero 4K + no longer visible on local network

After running:

sudo rm -r /etc/samba/

I get:

rm: cannot remove '/etc/samba/': No such file or directory

And then after running:

sudo apt-get install smb-app-osmc

I get:

Reading package lists... Done
Building dependency tree
Reading state information... Done
The following additional packages will be installed:
  python-samba samba samba-common samba-common-bin
Suggested packages:
  bind9 bind9utils ctdb ldb-tools smbldap-tools ufw winbind heimdal-clients
Recommended packages:
  python-gpg attr logrotate samba-dsdb-modules samba-vfs-modules
The following NEW packages will be installed:
  python-samba samba samba-common samba-common-bin smb-app-osmc
0 upgraded, 5 newly installed, 0 to remove and 0 not upgraded.
Need to get 3588 kB of archives.
After this operation, 29.1 MB of additional disk space will be used.
Do you want to continue? [Y/n] Y
Get:1 http://security.debian.org buster/updates/main armhf python-samba armhf 2:4.9.5+dfsg-5+deb10u1 [1812 kB]
Get:3 http://security.debian.org buster/updates/main armhf samba-common all 2:4.9.5+dfsg-5+deb10u1 [170 kB]
Get:4 http://security.debian.org buster/updates/main armhf samba-common-bin armhf 2:4.9.5+dfsg-5+deb10u1 [579 kB]
Get:5 http://security.debian.org buster/updates/main armhf samba armhf 2:4.9.5+dfsg-5+deb10u1 [1024 kB]
Get:2 http://ftp.fau.de/osmc/osmc/apt buster/main armhf smb-app-osmc all 1.2.4 [3484 B]
Fetched 3588 kB in 0s (11.2 MB/s)
Preconfiguring packages ...
Selecting previously unselected package python-samba.
(Reading database ... 29094 files and directories currently installed.)
Preparing to unpack .../python-samba_2%3a4.9.5+dfsg-5+deb10u1_armhf.deb ...
Unpacking python-samba (2:4.9.5+dfsg-5+deb10u1) ...
Preparing to unpack .../samba-common_2%3a4.9.5+dfsg-5+deb10u1_all.deb ...
Unpacking samba-common (2:4.9.5+dfsg-5+deb10u1) ...
Selecting previously unselected package samba-common-bin.
Preparing to unpack .../samba-common-bin_2%3a4.9.5+dfsg-5+deb10u1_armhf.deb ...
Unpacking samba-common-bin (2:4.9.5+dfsg-5+deb10u1) ...
Preparing to unpack .../samba_2%3a4.9.5+dfsg-5+deb10u1_armhf.deb ...
Unpacking samba (2:4.9.5+dfsg-5+deb10u1) ...
Setting up python-samba (2:4.9.5+dfsg-5+deb10u1) ...
Setting up samba-common (2:4.9.5+dfsg-5+deb10u1) ...
Not replacing deleted config file /etc/samba/smb.conf
Install/upgrade will fail. To recover, please try:
 sudo cp /usr/share/samba/smb.conf /etc/samba/smb.conf
 sudo dpkg --configure -a
Setting up samba-common-bin (2:4.9.5+dfsg-5+deb10u1) ...
Checking smb.conf with testparm
Load smb config files from /etc/samba/smb.conf
Error loading services.
dpkg: error processing package samba-common-bin (--configure):
 installed samba-common-bin package post-installation script subprocess returned error exit status 1
dpkg: dependency problems prevent configuration of samba:
 samba depends on samba-common-bin (= 2:4.9.5+dfsg-5+deb10u1); however:
  Package samba-common-bin is not configured yet.

dpkg: error processing package samba (--configure):
 dependency problems - leaving unconfigured
Errors were encountered while processing:
 samba-common-bin
 samba
E: Sub-process /usr/bin/dpkg returned an error code (1)

Ok, not 100% sure which state we are in now. Try
sudo dpkg --configure -a
sudo apt-get -f install
sudo apt-get --reinstall install smb-app-osmc

sudo dpkg --configure -a

gives:

Setting up samba-common-bin (2:4.9.5+dfsg-5+deb10u1) ...
Checking smb.conf with testparm
Load smb config files from /etc/samba/smb.conf
Error loading services.
dpkg: error processing package samba-common-bin (--configure):
 installed samba-common-bin package post-installation script subprocess returned error exit status 1
dpkg: dependency problems prevent configuration of samba:
 samba depends on samba-common-bin (= 2:4.9.5+dfsg-5+deb10u1); however:
  Package samba-common-bin is not configured yet.

dpkg: error processing package samba (--configure):
 dependency problems - leaving unconfigured
Errors were encountered while processing:
 samba-common-bin
 samba

Should I proceed with the other commands?

Yeah try the other commands and see what happens otherwise we need to try to remove samba-common-bin and samba.

sudo apt-get -f install

gives:

Reading package lists... Done
Building dependency tree
Reading state information... Done
The following packages were automatically installed and are no longer required:
  python-samba samba samba-common samba-common-bin
Use 'sudo apt autoremove' to remove them.
0 upgraded, 0 newly installed, 0 to remove and 0 not upgraded.
2 not fully installed or removed.
After this operation, 0 B of additional disk space will be used.
Setting up samba-common-bin (2:4.9.5+dfsg-5+deb10u1) ...
Checking smb.conf with testparm
Load smb config files from /etc/samba/smb.conf
Error loading services.
dpkg: error processing package samba-common-bin (--configure):
 installed samba-common-bin package post-installation script subprocess returned error exit status 1
dpkg: dependency problems prevent configuration of samba:
 samba depends on samba-common-bin (= 2:4.9.5+dfsg-5+deb10u1); however:
  Package samba-common-bin is not configured yet.

dpkg: error processing package samba (--configure):
 dependency problems - leaving unconfigured
Errors were encountered while processing:
 samba-common-bin
 samba
E: Sub-process /usr/bin/dpkg returned an error code (1)

And then

sudo apt-get --reinstall install smb-app-osmc

gives

Reading package lists... Done
Building dependency tree
Reading state information... Done
The following NEW packages will be installed:
  smb-app-osmc
0 upgraded, 1 newly installed, 0 to remove and 0 not upgraded.
2 not fully installed or removed.
Need to get 0 B/3484 B of archives.
After this operation, 68.6 kB of additional disk space will be used.
Setting up samba-common-bin (2:4.9.5+dfsg-5+deb10u1) ...
Checking smb.conf with testparm
Load smb config files from /etc/samba/smb.conf
Error loading services.
dpkg: error processing package samba-common-bin (--configure):
 installed samba-common-bin package post-installation script subprocess returned error exit status 1
dpkg: dependency problems prevent configuration of samba:
 samba depends on samba-common-bin (= 2:4.9.5+dfsg-5+deb10u1); however:
  Package samba-common-bin is not configured yet.

dpkg: error processing package samba (--configure):
 dependency problems - leaving unconfigured
Errors were encountered while processing:
 samba-common-bin
 samba
E: Sub-process /usr/bin/dpkg returned an error code (1)

Ok, suggest to carefully try to remove samba-common-bin as soon as you see a warning about a Vero package being removed say no.
sudo apt-get purge samba-common-bin

If that goes without issue try again
sudo dpkg --configure -a
sudo apt-get -f install
sudo apt-get --reinstall install smb-app-osmc

Here is the output from the 4 commands in your last post:

osmc@osmc-oggie:~$ sudo apt-get purge samba-common-bin
Reading package lists... Done
Building dependency tree
Reading state information... Done
The following packages were automatically installed and are no longer required:
  python-samba samba-common
Use 'sudo apt autoremove' to remove them.
The following packages will be REMOVED:
  samba* samba-common-bin*
0 upgraded, 0 newly installed, 2 to remove and 0 not upgraded.
2 not fully installed or removed.
After this operation, 16.9 MB disk space will be freed.
Do you want to continue? [Y/n] y
(Reading database ... 29669 files and directories currently installed.)
Removing samba (2:4.9.5+dfsg-5+deb10u1) ...
Removing samba-common-bin (2:4.9.5+dfsg-5+deb10u1) ...
Processing triggers for libc-bin (2.28-10) ...
(Reading database ... 29424 files and directories currently installed.)
Purging configuration files for samba (2:4.9.5+dfsg-5+deb10u1) ...
Processing triggers for systemd (241-7~deb10u7) ...
osmc@osmc-oggie:~$ sudo dpkg --configure -a
osmc@osmc-oggie:~$ sudo apt-get -f install
Reading package lists... Done
Building dependency tree
Reading state information... Done
The following packages were automatically installed and are no longer required:
  python-samba samba-common
Use 'sudo apt autoremove' to remove them.
0 upgraded, 0 newly installed, 0 to remove and 0 not upgraded.
osmc@osmc-oggie:~$ sudo apt-get --reinstall install smb-app-osmc
Reading package lists... Done
Building dependency tree
Reading state information... Done
The following additional packages will be installed:
  samba samba-common-bin
Suggested packages:
  bind9 bind9utils ctdb ldb-tools smbldap-tools ufw winbind heimdal-clients
Recommended packages:
  attr logrotate samba-dsdb-modules samba-vfs-modules
The following NEW packages will be installed:
  samba samba-common-bin smb-app-osmc
0 upgraded, 3 newly installed, 0 to remove and 0 not upgraded.
Need to get 0 B/1606 kB of archives.
After this operation, 16.9 MB of additional disk space will be used.
Do you want to continue? [Y/n] y
Selecting previously unselected package samba-common-bin.
(Reading database ... 29417 files and directories currently installed.)
Preparing to unpack .../samba-common-bin_2%3a4.9.5+dfsg-5+deb10u1_armhf.deb ...
Unpacking samba-common-bin (2:4.9.5+dfsg-5+deb10u1) ...
Selecting previously unselected package samba.
Preparing to unpack .../samba_2%3a4.9.5+dfsg-5+deb10u1_armhf.deb ...
Unpacking samba (2:4.9.5+dfsg-5+deb10u1) ...
Setting up samba-common-bin (2:4.9.5+dfsg-5+deb10u1) ...
Checking smb.conf with testparm
Load smb config files from /etc/samba/smb.conf
Error loading services.
dpkg: error processing package samba-common-bin (--configure):
 installed samba-common-bin package post-installation script subprocess returned error exit status 1
dpkg: dependency problems prevent configuration of samba:
 samba depends on samba-common-bin (= 2:4.9.5+dfsg-5+deb10u1); however:
  Package samba-common-bin is not configured yet.

dpkg: error processing package samba (--configure):
 dependency problems - leaving unconfigured
Errors were encountered while processing:
 samba-common-bin
 samba
E: Sub-process /usr/bin/dpkg returned an error code (1)

Damn, something is really messed up.
What is the output of ls -lah /etc/samba

Thanks for your patience, I’m totally out of my depth with this!

Here is the output of ls -lah /etc/samba

total 12K
drwxr-xr-x  3 root root 4.0K Apr  7 15:24 .
drwxr-xr-x 79 root root 4.0K Apr  7 15:22 ..
drwxr-xr-x  2 root root 4.0K Sep  2  2019 tls

No worries, as it partly went wrong on my purge command :slight_smile:
Can you try
dpkg install --reinstall samba-common

Alternatively create a smb.conf in /etc/samba/ with this content

[global]

# If you require a fully custom smb.conf create smb-local.conf instead of editing smb.conf so your
# configuration will not be overwritten by samba upgrades. You can use smb.conf as a template by
# copying it to smb-local.conf then removing the config file line below in the new file. If you only
# need to add some additional shares see smb-shares.conf below for a simpler way to do this.

    config file = /etc/samba/smb-local.conf

    workgroup = WORKGROUP
    security=user
    follow symlinks = yes
    wide links = no
    unix extensions = no
    lock directory = /var/cache/samba
    load printers = no
    printing = bsd
    printcap name = /dev/null
    disable spoolss = yes
    log level = 1
    map to guest = bad user
    fruit:model = Macmini
#   usershare template share = automount template

# Automount template disabled to work around a samba bug causing crashes accessing external drives.

    read raw = Yes
    write raw = Yes
    strict locking = no
    min receivefile size = 16384
    use sendfile = true
    aio read size = 2048
    aio write size = 2048
    socket options = TCP_NODELAY IPTOS_LOWDELAY SO_RCVBUF=131072 SO_SNDBUF=131072

[osmc]
    browsable = yes
    read only = no
    valid users = osmc
    path = /home/osmc
    comment = OSMC Home Directory

[automount template]
    browseable = yes
    -valid = no
    valid users = osmc
    path = %P
    hide files = /$RECYCLE.BIN/System Volume Information/desktop.ini/thumbs.db/

# Add custom shares in smb-shares.conf instead of editing smb.conf so they will not be
# overwritten by samba updates. You can only add new shares to smb-shares.conf, not change
# the default shares or global options. If you need full control see smb-local.conf above.

include = /etc/samba/smb-shares.conf
dpkg install --reinstall samba-common

gives:

dpkg: error: need an action option

Type dpkg --help for help about installing and deinstalling packages [*];
Use 'apt' or 'aptitude' for user-friendly package management;
Type dpkg -Dhelp for a list of dpkg debug flag values;
Type dpkg --force-help for a list of forcing options;
Type dpkg-deb --help for help about manipulating *.deb files;

Options marked [*] produce a lot of output - pipe it through 'less' or 'more' !

That should be

sudo apt-get install --reinstall samba-common

What command would I need to input to create smb.conf in /etc/samba/?

Inputting sudo apt-get install --reinstall samba-common

gives me

Reading package lists... Done
Building dependency tree
Reading state information... Done
The following package was automatically installed and is no longer required:
  samba
Use 'sudo apt autoremove' to remove it.
0 upgraded, 0 newly installed, 1 reinstalled, 0 to remove and 0 not upgraded.
2 not fully installed or removed.
Need to get 0 B/170 kB of archives.
After this operation, 0 B of additional disk space will be used.
Preconfiguring packages ...
(Reading database ... 29668 files and directories currently installed.)
Preparing to unpack .../samba-common_2%3a4.9.5+dfsg-5+deb10u1_all.deb ...
Unpacking samba-common (2:4.9.5+dfsg-5+deb10u1) over (2:4.9.5+dfsg-5+deb10u1) ...
Setting up samba-common (2:4.9.5+dfsg-5+deb10u1) ...
Not replacing deleted config file /etc/samba/smb.conf
Install/upgrade will fail. To recover, please try:
 sudo cp /usr/share/samba/smb.conf /etc/samba/smb.conf
 sudo dpkg --configure -a
Setting up samba-common-bin (2:4.9.5+dfsg-5+deb10u1) ...
Checking smb.conf with testparm
Load smb config files from /etc/samba/smb.conf
Error loading services.
dpkg: error processing package samba-common-bin (--configure):
 installed samba-common-bin package post-installation script subprocess returned error exit status 1
dpkg: dependency problems prevent configuration of samba:
 samba depends on samba-common-bin (= 2:4.9.5+dfsg-5+deb10u1); however:
  Package samba-common-bin is not configured yet.

dpkg: error processing package samba (--configure):
 dependency problems - leaving unconfigured
Errors were encountered while processing:
 samba-common-bin
 samba
E: Sub-process /usr/bin/dpkg returned an error code (1)

As the error message says, please try:

 sudo cp /usr/share/samba/smb.conf /etc/samba/smb.conf
 sudo dpkg --configure -a

Try first the last step from @dillthedog
But the command to edit that file would be
nano /etc/samba/smb.conf

I’m back in! I figured that the username and password would revert to default after reinstalling samba and sure enough I was able to log in on my wireless devices using osmc for both. Strangely, I can still access all my Vero shares on Windows without changing anything.

How can I change my samba password to match with the password that I use for SSH?

Thanks so much for all your help guys!

smbpasswd

When I input smbpasswd

It says:

Old SMB password:
New SMB password:
Retype new SMB password:
SAMR connection to machine 127.0.0.1 failed. Error was NT_STATUS_ACCESS_DENIED, but LANMAN password changes are disabled

It still uses osmc as the password after.