Bug 16890

Summary: draksambashare fails to start without or with empty smb.conf
Product: Mageia Reporter: Helge Hielscher <hhielscher>
Component: RPM PackagesAssignee: Nicolas Lécureuil <mageia>
Status: NEW --- QA Contact:
Severity: normal    
Priority: Normal CC: anaselli, fri, nic, philippe.mallocci, pterjan, thierry.vignaud
Version: 8   
Target Milestone: ---   
Hardware: x86_64   
OS: Linux   
See Also: https://bugs.mageia.org/show_bug.cgi?id=30090
Whiteboard:
Source RPM: drakx-net-2.55-1.mga8.src.rpm CVE:
Status comment:

Description Helge Hielscher 2015-10-03 23:18:07 CEST
Description of problem:
# mv /etc/samba/smb.conf /etc/samba/smb.conf.20151003
# draksambashare 
Ignore the following Glib::Object::Introspection & Gtk3 warnings
Subroutine Gtk3::main redefined at /usr/lib/perl5/vendor_perl/5.22.0/Gtk3.pm line 525.
atom n� 0 is not a section

# touch /etc/samba/smb.conf
# draksambashare 
Ignore the following Glib::Object::Introspection & Gtk3 warnings
Subroutine Gtk3::main redefined at /usr/lib/perl5/vendor_perl/5.22.0/Gtk3.pm line 525.
atom n� 0 is not a section


Version-Release number of selected component (if applicable): drakx-net-2.23-1.mga6.src.rpm


How reproducible: always

Expected Result: draksambashare creates a valid smb.conf

Reproducible: 

Steps to Reproduce:
Samuel Verschelde 2015-10-12 10:24:43 CEST

Assignee: bugsquad => mageia
CC: (none) => anaselli, pterjan, thierry.vignaud

Comment 1 Olivier Blin 2016-01-30 16:28:37 CET
I can't reproduce with current Cauldron, do you have samba installed?

Ever confirmed: 1 => 0
Status: NEW => UNCONFIRMED

Comment 2 Nic Baxter 2016-03-01 05:37:51 CET
I can reproduce this report in mga6 upgraded from mga5.

Install drakwizard and run draksambashare and am prompted to install samba.
then configure samba using draksambashare.
Delete smb.conf and rerun draksambashare, output

'draksambashare 
Ignore the following Glib::Object::Introspection & Gtk3 warnings
Subroutine Gtk3::main redefined at /usr/lib/perl5/vendor_perl/5.22.0/Gtk3.pm line 525.
atom n� 0 is not a section'

So the question is should draksambashare wizard create smb.conf if it is missing or invalid?

My response is no. smb.conf is part of the samba-server package not draksambashare.

Any comments?

Status: UNCONFIRMED => NEW
Ever confirmed: 0 => 1
CC: (none) => nic

Comment 3 katnatek 2018-03-02 22:33:45 CET
Confirmed, the strage is if draksambashare is run for first time works well
The issue is when you clear of remove the file smb.conf
Comment 4 katnatek 2018-03-02 22:37:59 CET
To workarround i put some basic information in smb.conf

# Global parameters
[global]
       workgroup = HOME
       netbios name = SAMBA
       server string = Samba Server %v
       map to guest = Bad User
       log file = /var/log/samba/log.%m
       max log size = 50
       preferred master = No
       local master = No
       security = User

with that draksambashare start
Comment 5 katnatek 2018-03-03 03:14:35 CET
(In reply to katnatek from comment #4)
> To workarround i put some basic information in smb.conf
> 
> # Global parameters
> [global]
>        workgroup = HOME
>        netbios name = SAMBA
>        server string = Samba Server %v
>        map to guest = Bad User
>        log file = /var/log/samba/log.%m
>        max log size = 50
>        preferred master = No
>        local master = No
>        security = User
> 
> with that draksambashare start

Run but stuck in the final step if you try to reconfigure samba
Comment 6 Nicolas Lécureuil 2019-02-17 19:49:49 CET
still valid. 

I will try to take a look

CC: (none) => mageia

Comment 7 Nicolas Lécureuil 2019-02-17 20:04:45 CET
what is the best ? add a dummy config file or restart the wizard ?

I would vote for the second option.
Comment 8 Lewis Smith 2022-04-07 21:03:14 CEST
I am reviving & updating this bug because exactly the same problem has arisen with Mageia 8. This old bug has more information than the new.
Duplicate to announce.

See Also: (none) => https://bugs.mageia.org/show_bug.cgi?id=30090
Source RPM: drakx-net-2.23-1.mga6.src.rpm => drakx-net-2.55-1.mga8.src.rpm
CC: mageia => lewyssmith
Assignee: mageia => mageia
Version: Cauldron => 8

Comment 9 Lewis Smith 2022-04-07 21:12:23 CEST
*** Bug 30252 has been marked as a duplicate of this bug. ***

CC: (none) => philippe.mallocci

Comment 10 philippe malloci 2022-04-10 19:17:29 CEST
update from Bug 30252: 
I didn't manage to start draksambashare with the smb.conf file provided above but it works fine with the default .conf file coming from Linux Mint. Looking forward to reading from you.
Comment 11 Pascal Terjan 2022-04-10 19:32:06 CEST
So it fails to start when there is an invalid smb.conf (which is the case when it is empty or missing). The obvious fix for it (creating a file with default values when it fails to read any part of it) would be very risky so it should probably instead ask a question like "Failed to load a valid smb.conf, start with a default configuration? WARNING any custom configuration of Samba will be lost." and not silently overwrite existing invalid config.
Lewis Smith 2022-04-14 10:34:11 CEST

CC: lewyssmith => (none)

Comment 12 Morgan Leijström 2023-06-24 08:42:13 CEST
The suggestion in Comment 11 sound good.

Can we have this bug finally resolved?

For 9 RC, or in Cauldron after release?

CC: (none) => fri