Clustering - node panic/reboot after enabling samba resource

Hi there,

I configured the samba data service as shown in the standard doc examples:

http://docs.sun.com/app/docs/doc/819-3063

resp. the example from sun cluster oasis:

http://blogs.sun.com/SC/entry/new_solaris_10_experience

I can even register it with the following settings:


/opt/SUNWscsmb/util/samba_config:

#+++ Resource Specific Parameters+

RS=samba-pdc

RG=samba-rg

RS_LH=samba-lh

RS_HAS=samba-has

RUN_NMBD=YES

SERVICES="smbd,nmbd"

#+++ Common Parameters+

BINDIR=/opt/csw/bin

SBINDIR=/opt/csw/sbin

CFGDIR=/ZFSsamba/nero

LDPATH=/opt/csw/lib

FMUSER=fmuser

#+++ SMBD & NMBD Specific Parameters (See Note 1)+

SAMBA_LOGDIR=/ZFSsamba/nero/logs

SAMBA_FMPASS=samba

SAMBA_FMDOMAIN=kfz

TIMEOUT=3000


The clresource enable command (clreource enable samba-pdc) doesn't complain either,

but seconds later the node (single node test-cluster) panics and reboots.

here are the corresponding log messages:


/var/adm/messages:

Mar 28 15:35:57 nero SC[SUNWscsmb.samba.start]:samba-rg:samba-pdc: [ID 287111 daemon.error] Validate - RUN_NMBD= is invalid - specify YES or NO

Mar 28 15:35:57 nero Cluster.PMF.pmfd: [ID 887656 daemon.notice] Process: tag="samba-rg,samba-pdc,0.svc", cmd="/bin/sh -c /opt/SUNWscsmb/samba/bin/start_samba -R 'samba-p dc' -G 'samba-rg' -X 'smbd nmbd' -B '/opt/csw/bin' -S '/opt/csw/sbin' -C '/ZFSsamba/nero' -L '/ZFSsamba/nero/logs' -U kfz\\\\fmuser%samba -M 'scmondir' -P '/opt/csw/lib' -H nero-lh1 ", Failed to stay up.

...

Mar 28 15:35:57 nero Cluster.PMF.pmfd: [ID 819736 daemon.notice] PMF is restarting process that died: tag=samba-rg,samba-pdc,0.svc, cmd_path=/bin/sh -c /opt/SUNWscsmb/sam ba/bin/start_samba -R 'samba-pdc' -G 'samba-rg' -X 'smbd nmbd' -B '/opt/csw/bin' -S '/opt/csw/sbin' -C '/ZFSsamba/nero' -L '/ZFSsamba/nero/logs' -U kfz\\\\fmuser%samba -M 'scmondir' -P '/opt/csw/lib' -H nero-lh1 , max_retries=0, num_retries=0

...

Mar 28 15:35:57 nero Cluster.PMF.pmfd: [ID 534408 daemon.notice] "samba-rg,samba-pdc,0.svc" restarting too often ... sleeping 1 seconds.

...

Mar 28 15:36:49 nero ^Mpanic[cpu0]/thread=fffffe80000b9c80:

Mar 28 15:36:49 nero genunix: [ID 562397 kern.notice] Failfast: Aborting zone "global" (zone ID 0) because "pmfd" died 35 seconds ago.

/var/cluster/logs/DS/samba-rg/samba-pdc/probe_log.txt:

03/28/2007 15:19:43 nero PROBE-INFO> Probe has been executed with exit code 0 [/opt/SUNWscsmb/samba/bin/probe_samba -R 'samba-pdc' -G 'samba-rg' -X 'smbd nmbd' -B '/opt/csw/bin' -S '/opt/csw/sbin' -C '/ZFSsamba/nero' -L '/ZFSsamba/nero/logs' -U kfz\\\\fmuser%samba -M 'scmondir' -P '/opt/csw/lib' -H nero-lh1 ]

/var/cluster/logs/DS/samba-rg/samba-pdc/start_stop_log.txt:

03/28/2007 14:53:29 nero START-INFO> Start succeeded. [/opt/SUNWscsmb/samba/bin/start_samba -R 'samba-pdc' -G 'samba-rg' -X 'smbd nmbd' -B '/opt/csw/bin' -S '/opt/csw/sbin' -C '/ZFSsamba/nero' -L '/ZFSsamba/nero/logs' -U kfz\\\\fmuser%samba -M 'scmondir' -P '/opt/csw/lib' -H nero-lh1 ]

03/28/2007 14:53:51 nero STOP-ERROR> Failed to take the resource out of PMF control. Sending SIGKILL now.

03/28/2007 14:53:51 nero STOP-ERROR> Failed to stop the application with SIGKILL. Returning with failure from stop method.


As you can see although I set it explicitly to YES in samba_config: Validate - RUN_NMBD= is invalid - specify YES or NO

OS: Solaris 10 11/06

Sun Cluster 3.2

Maybe someone knows how to solve this.

Greetings

Jochem Ippers

[3859 byte] By [jochem_ippersa] at [2007-11-26 23:15:18]
# 1

Hi Jochem,

I'm a bit confused with your samba_config file, i.e. I see you've added

RUN_NMBD=YES

whereas within the docs you've listed that variable is not listed, i.e.

http://docs.sun.com/app/docs/doc/819-3063/6n5ae9m0b?a=view

Anyway, I'm assuming the rest of the SC 3.2 agent is unchanged as such please can you verify that you can start Samba from /usr/csw/bin in a standalone manner, i.e. not under Solaris Cluster control.

If this works, can you then stop Samba manually and then issue the following commands

1. Remove RUN_NMBD=YES from samba_confdig and reregister the resource.

2. Edit /etc/syslog.conf and amend the /var/adm/messages line as follows

*.err;kern.debug;daemon.debug;mail.crit /var/adm/messages

3. svcadm disable system-log; svcadm enable system-log

4. Edit /opt/SUNWscsmb/samba/etc/config and set DEBUG=ALL

5. clrs show -p Start_command samba-pdc

6. Ensure the IP address and Zpool are up/imported on the node

7. Issue the Start_command as follows, i.e. use the Start_command output from #5. Looking at your output it will be something like this

ksh -x /opt/SUNWscsmb/samba/bin/start_samba -R 'samba-p dc' -G 'samba-rg' -X 'smbd nmbd' -B '/opt/csw/bin' -S '/opt/csw/sbin' -C '/ZFSsamba/nero' -L '/ZFSsamba/nero/logs' -U 'kfz\\\\fmuser%samba' -M 'scmondir' -P '/opt/csw/lib' -H <IP address>

However, please note the "ksh -x" at the beginning and <IP address> at the end, i.e. supply the actual IP address instead of "nero-lh1". I've also quoted 'kfz\\\\fmuser%samba'.

This will execute the Start_command in debug mode. If the error is not clear from this, then please post the output.

If this works, then reissue the "ksh -x ..." command but substitute "start_samba" with "probe_samba" and then "stop_samba".

If these work then undo the debug stuff earlier on and ensure that Samba is not running, i.e. pkill -TERM smbd; pkill -TERM nmbd and enable the resource via clrs.

I somehow suspect the issue is with /usr/csw/bin, have you tried Samba that is packaged with Solaris 10, i.e. at /usr/sfw/bin. I wonder why you've download Samba from blastwave.org, i.e. /opt/csw.

Regards

Neil

neil_garthwaitea at 2007-7-10 14:14:59 > top of Java-index,Solaris Operating System,Solaris Essentials - General Technical Questions...
# 2

Hi Neil,

thanks for the tips, they helped me a lot, especially the "quote" hint. :-)

The bundled samba version didn't work either.

I had to change the /opt/SUNWscsmb/samba/bin/functions file to get it running (some variables are lost).

It's just a quick+dirty change but maybe other people can use it too.

I don't use winbind here, just smbd and nmbd, so one will probably have to make similar changes for it.

my /opt/SUNWscsmb/samba/bin/functions:

# ensure the following assignment appears at the beginning of the file

NMBD=${SBINDIR}/nmbd

# in function validate_samba() change the line/assignment:

RUN_NMBD=`/usr/bin/echo ${RUN_NMBD} | /usr/bin/tr -s '[:lower:]' '[:upper:]'`

# to:

RUN_NMBD="YES"

# in function start_samba() change the line:

for i in ${SERVICES}

# to:

for i in NMBD SMBD

This worked with the following samba_config:

#+++ Resource Specific Parameters +

RS=samba-pdc

RG=samba-rg

RS_LH=samba-lh

RS_HAS=samba-has

SERVICES="smbd,nmbd"

#+++ Common Parameters +

BINDIR=/opt/csw/bin

SBINDIR=/opt/csw/sbin

CFGDIR=/ZFSsamba/nero/lib

LDPATH=/opt/csw/lib

FMUSER=fmuser

#+++ SMBD & NMBD Specific Parameters (See Note 1) +

SAMBA_LOGDIR=/ZFSsamba/nero/logs

SAMBA_FMPASS=samba

SAMBA_FMDOMAIN=kfz

TIMEOUT=3000

Greetings from Aachen,Germany

Jochem

jochem_ippersa at 2007-7-10 14:15:00 > top of Java-index,Solaris Operating System,Solaris Essentials - General Technical Questions...
# 3

Hi Jochem,

I'm sorry I can't agree with your analysis. The fact that you have now modified the agent means that it's not suported anymore. Also if you apply patches for the agent you will overwrite the changes you've made, which I would argue were not required in the first place.

When you first posted, I noted that you had modified /opt/SUNWscsmb/util/samba_config with RUN_NMBD=YES, although I now suspect that further modifications may have been made. Unfortunately you have not provided any output to my previous request, so I can't help beyond my conclusion above.

In summary I can't agree with your analysis and also would not recommend others to follow suit. I have just reconfirmed that the Samba agent is working and do not get the errors you first listed. If you do find an issue with the Samba agent for Solaris Cluster, then please either raise a support call or post the output I requested earlier.

Regards

Neil

neil_garthwaitea at 2007-7-10 14:15:00 > top of Java-index,Solaris Operating System,Solaris Essentials - General Technical Questions...
# 4
Hi Neil,sorry for now, I will post it over/after the weekend.ByeGreetingsJochem
jochem_ippersa at 2007-7-10 14:15:00 > top of Java-index,Solaris Operating System,Solaris Essentials - General Technical Questions...
# 5

Hi again Neil,

sorry but I had to get the samba cluster resource running as fast as i could and so I was just glad to get it running somehow, so my last posting was a little fast. I couldn't and still can't search for the real cause of my problem (time pressure here). Maybe my (shell-) environment or anything completely different from the agent scripts is the problem (when the error occurs the NMBD variable is empty).Of course I would prefer the original agent scripts myself.

my PATH for user root:

/usr/sbin:/usr/xpg6/bin:/usr/xpg4/bin:/usr/bin:/usr/openwin/bin:/usr/ccs/bin:/usr/ucb:

/opt/csw/bin:/opt/csw/sbin:/opt/sfw/bin:/opt/sfw/cups/bin:/opt/sfw/netpbm/bin:/usr/demo/jds/bin:

/usr/sfw/bin:/usr/dt/bin:/usr/X11/bin:/opt/SUNWdsee:/opt/SUNWdsee/dsee6/bin:

/opt/SUNWdsee/dsee6/lib/bin:/opt/SUNWdsee/dscc6/lib/bin:

/opt/SUNWdsee/dscc6/bin:/opt/SUNWdsee/ds6/bin:/opt/SUNWdsee/dps6/bin:/usr/sadm/bin:

/usr/sadm/install/bin:/usr/sadm/sysadm/bin:/usr/sadm/lib/smc/bin:/usr/sadm/admin/bin:

/opt/csw/bin::/usr/cluster/bin:/opt/SUNWexplo/bin

I deleted the samba-pdc resource and registered the samba_config I posted last time with the original scripts again (The RUN_NMBD=YES was just a relic.) Below is the outpost of:

ksh -x /opt/SUNWscsmb/samba/bin/start_samba -R 'samba-pdc' -G 'samba-rg' -X 'smbd nmbd' -B '/opt/csw/bin' -S '/opt/csw/sbin' -C '/ZFSsamba/nero' -L '/ZFSsamba/nero/l

ogs' -U 'kfz\\\\fmuser%samba' -M 'scmondir' -P '/opt/csw/lib' -H samba-lh1

Greetings

Jochem

+ + basename /opt/SUNWscsmb/samba/bin/start_samba

MYNAME=start_samba

+ + /usr/bin/awk -F_ {print $1}

+ /usr/bin/echo start_samba

parm1=start

+ + /usr/bin/awk -F_ {print $2}

+ /usr/bin/echo start_samba

parm2=samba

+ /opt/SUNWscsmb/bin/control_samba -R samba-pdc -G samba-rg -X smbd nmbd -B /opt/csw/bin -S /opt/csw/sbin -C /ZFSsamba/nero -L /ZFSsamba/nero/logs -U kfz\\\\fmuser%samba -M scmondir -P /opt/csw/lib -H nero-lh1 start samba

+ print SC[SUNWscsmb.samba.start]:samba-rg:samba-pdc

+ validate_common

+ print SC[SUNWscsmb.samba.start]:samba-rg:samba-pdc

+ rc=0

+ [ ! -d /opt/csw/bin ]

+ debug_message Validate - samba bin directory /opt/csw/bin exists

+ print SC[SUNWscsmb.samba.start]:samba-rg:samba-pdc

+ [ ! -d /opt/csw/sbin ]

+ debug_message Validate - samba sbin directory /opt/csw/sbin exists

+ print SC[SUNWscsmb.samba.start]:samba-rg:samba-pdc

+ [ ! -d /ZFSsamba/nero ]

+ debug_message Validate - samba configuration directory /ZFSsamba/nero exists

+ print SC[SUNWscsmb.samba.start]:samba-rg:samba-pdc

+ [ ! -f /ZFSsamba/nero/lib/smb.conf ]

+ debug_message Validate - smbconf /ZFSsamba/nero/lib/smb.conf exists

+ print SC[SUNWscsmb.samba.start]:samba-rg:samba-pdc

+ [ ! -x /opt/csw/bin/nmblookup ]

+ debug_message Validate - nmblookup /opt/csw/bin/nmblookup exists and is executable

+ print SC[SUNWscsmb.samba.start]:samba-rg:samba-pdc

+ /opt/csw/bin/nmblookup -h

+ 1> /dev/null 2>& 1

+ [ 1 -eq 0 ]

+ + /usr/bin/awk {print $2}

+ /opt/csw/bin/nmblookup -V

VERSION=3.0.23b

+ + /usr/bin/cut -d. -f1

+ /usr/bin/echo 3.0.23b

SAMBA_VERSION=3

+ + /usr/bin/cut -d. -f2

+ /usr/bin/echo 3.0.23b

SAMBA_RELEASE=0

+ + /usr/bin/cut -d. -f3

+ /usr/bin/echo 3.0.23b

SAMBA_UPDATE=23b

+ debug_message Validate - Samba version <3.0.23b> is being used

+ print SC[SUNWscsmb.samba.start]:samba-rg:samba-pdc

+ + stripfunc 3

SAMBA_VERSION=3

+ + stripfunc 0

SAMBA_RELEASE=0

+ + stripfunc 23b

SAMBA_UPDATE=23

+ rc_validate_version=0

+ [ -z 3.0.23b ]

+ [ 3 -lt 2 ]

+ [ 3 -eq 2 -a 0 -le 2 -a 23 -lt 2 ]

+ [ 0 -gt 0 ]

+ debug_message Function: validate_common - End

+ print SC[SUNWscsmb.samba.start]:samba-rg:samba-pdc

+ return 0

+ rc1=0

+ validate_samba

+ print SC[SUNWscsmb.samba.start]:samba-rg:samba-pdc

+ rc=0

+ [ ! -d /ZFSsamba/nero/logs ]

+ debug_message Validate - Samba log directory /ZFSsamba/nero/logs exists

+ print SC[SUNWscsmb.samba.start]:samba-rg:samba-pdc

+ [ ! -x /opt/csw/sbin/smbd ]

+ debug_message Validate - smbd /opt/csw/sbin/smbd exists and is executable

+ print SC[SUNWscsmb.samba.start]:samba-rg:samba-pdc

+ [ ! -x ]

+ syslog_tag

+ print SC[SUNWscsmb.samba.start]:samba-rg:samba-pdc

+ scds_syslog -p daemon.error -t SC[SUNWscsmb.samba.start]:samba-rg:samba-pdc -m Validate - nmbd %s non-existent executable

+ rc=1

+ /usr/bin/grep scmondir

+ /usr/bin/cut -d] -f1

+ /usr/bin/cut -d[ -f2

+ /usr/bin/grep \[ /ZFSsamba/nero/lib/smb.conf

+ [ -z scmondir ]

+ debug_message Validate - Faultmonitor resource scmondir exists

+ print SC[SUNWscsmb.samba.start]:samba-rg:samba-pdc

+ [ ! -x /opt/csw/bin/smbclient ]

+ debug_message Validate - smbclient /opt/csw/bin/smbclient exists and is executable

+ print SC[SUNWscsmb.samba.start]:samba-rg:samba-pdc

+ + /usr/bin/cut -d% -f1

+ /usr/bin/awk BEGIN { FS="
" } {print $NF}

+ /usr/bin/echo kfz\\\\fmuser%samba

USER=fmuser

+ /usr/bin/getent passwd fmuser

+ [ -z fmuser:x:10000:10000::/home/fmuser: ]

+ debug_message Validate - Retrieved faultmonitor-user fmuser from the nameservice

+ print SC[SUNWscsmb.samba.start]:samba-rg:samba-pdc

+ + /usr/bin/tr -s [:lower:] [:upper:]

+ /usr/bin/echo YES

Fehlerhafte Zeichenkette

RUN_NMBD=

+ [ = YES -o = NO ]

+ syslog_tag

+ print SC[SUNWscsmb.samba.start]:samba-rg:samba-pdc

+ scds_syslog -p daemon.error -t SC[SUNWscsmb.samba.start]:samba-rg:samba-pdc -m Validate - RUN_NMBD=%s is invalid - specify YES or NO

+ rc=1

+ debug_message Function: validate_samba - End

+ print SC[SUNWscsmb.samba.start]:samba-rg:samba-pdc

+ return 1

+ rc2=1

+ rc=1

+ [ 0 -eq 0 -a 1 -eq 0 ]

+ [ 1 -eq 0 ]

+ rc=1

+ exit 1

+ rc=1

+ exit 1

jochem_ippersa at 2007-7-10 14:15:00 > top of Java-index,Solaris Operating System,Solaris Essentials - General Technical Questions...
# 6

Hi Jochem,

I agree that it appears that NMBD is not being set correctly. The NMBD variable is set within the control_samba script which does not normally output any debug messages. To resolve this please run the following and post the output,

1. pkginfo -l SUNWscsmb

2. pkgchk SUNWscsmb

3. Edit /opt/SUNWscsmb/bin/control_samba and amend the first line as follows,

#!/usr/bin/ksh -x

4. ksh -x /opt/SUNWscsmb/samba/bin/start_samba -R 'samba-pdc' -G 'samba-rg' -X 'smbd nmbd' -B '/opt/csw/bin' -S '/opt/csw/sbin' -C '/ZFSsamba/nero' -L '/ZFSsamba/nero/logs' -U 'kfz\\\\fmuser%samba' -M 'scmondir' -P '/opt/csw/lib' -H nero-lh1

Please note step 4 maybe incorrect as I note you have "-H samba-lh1" and also "-H nero-lh1", I've assumed the latter.

Regards

Neil

neil_garthwaitea at 2007-7-10 14:15:00 > top of Java-index,Solaris Operating System,Solaris Essentials - General Technical Questions...
# 7

Hi Neil,

I got a really mixed up installation here, because I want to use the newest features in SUN cluster (=3.2) and also in the just released Java Enterprise System 5 (Directory Server 6 etc.). And I want to use the next Samba release 3.0.25 which shall support the mapping of ZFS/NFS4 to WinNT acls.

Below is the output you requested.

Regards

Jochem

german <-> engl.:

"Fehler" = error

"fehlerhaft" = faulty/incorrect

"Zeichenkette" = string

pkginfo -l SUNWscsmb

PKGINST: SUNWscsmb

NAME: Sun Cluster HA for Samba

KATEGORIE: application

ARCH: i386

VERSION: 3.2.0,REV=2006.12.06.18.33

BASEDIR: /opt

VENDOR: Sun Microsystems, Inc.

DESC: Sun Cluster HA for Samba

PSTAMP: 12/06/2006.18:37:50

INSTDATE: Feb 16 2007 19:24

HOTLINE: Please contact your local service provider

STATUS: vollst鋘dig installiert

DATEIEN:30 installierte Pfadnamen

3 gemeinsam genutzte Pfadnamen

14 Verzeichnisse

12 ausf黨rbare Dateien

126 genutzte Bl鯿ke (gesch鋞zter Wert)

pkgchk SUNWscsmb

Fehler: /opt/SUNWscsmb/bin/control_samba

modtime <12/07/06 03:37:03 AM> expected <03/29/07 05:56:17 PM> actual

Fehler: /opt/SUNWscsmb/bin/functions

modtime <12/07/06 03:37:03 AM> expected <03/29/07 06:30:01 PM> actual

file size <27379> expected <27622> actual

file cksum <62511> expected <6213> actual

Fehler: /opt/SUNWscsmb/samba/etc/config

modtime <12/07/06 03:37:02 AM> expected <04/02/07 01:33:44 PM> actual

file size <195> expected <198> actual

file cksum <14285> expected <14502> actual

Fehler: /opt/SUNWscsmb/util/samba_config

modtime <12/07/06 03:37:03 AM> expected <03/29/07 06:31:01 PM> actual

file size <10234> expected <382> actual

file cksum <6181> expected <30113> actual

Fehler: /opt/SUNWscsmb/util/samba_register

modtime <12/07/06 03:37:03 AM> expected <03/29/07 05:53:33 PM> actual

ksh -x /opt/SUNWscsmb/samba/bin/start_samba -R 'samba-pdc' -G 'samba-rg' -X 'smbd nmbd' -B '/opt/csw/bin' -S '/opt/csw/sbin' -C '/ZFSsamba/nero' -L '/ZFSsamba/nero/logs' -U 'kfz\\\\fmuser%samba' -M 'scmondir' -P '/opt/csw/lib' -H nero-lh1

+ + basename /opt/SUNWscsmb/samba/bin/start_samba

MYNAME=start_samba

+ + /usr/bin/awk -F_ {print $1}

+ /usr/bin/echo start_samba

parm1=start

+ + /usr/bin/awk -F_ {print $2}

+ /usr/bin/echo start_samba

parm2=samba

+ /opt/SUNWscsmb/bin/control_samba -R samba-pdc -G samba-rg -X smbd nmbd -B /opt/csw/bin -S /opt/csw/sbin -C /ZFSsamba/nero -L /ZFSsamba/nero/logs -U kfz\\\\fmuser%samba -M scmondir -P /opt/csw/lib -H nero-lh1 start samba

+ + basename /opt/SUNWscsmb/bin/control_samba

MYNAME=control_samba

+ + dirname /opt/SUNWscsmb/bin/control_samba

MYDIR=/opt/SUNWscsmb/bin

+ typeset opt

+ getopts R:G:X:B:S:C:U:M:L:H:P:N:Y opt

+ RESOURCE=samba-pdc

+ getopts R:G:X:B:S:C:U:M:L:H:P:N:Y opt

+ RESOURCEGROUP=samba-rg

+ getopts R:G:X:B:S:C:U:M:L:H:P:N:Y opt

+ SERVICES=smbd nmbd

+ getopts R:G:X:B:S:C:U:M:L:H:P:N:Y opt

+ BINDIR=/opt/csw/bin

+ getopts R:G:X:B:S:C:U:M:L:H:P:N:Y opt

+ SBINDIR=/opt/csw/sbin

+ getopts R:G:X:B:S:C:U:M:L:H:P:N:Y opt

+ CFGDIR=/ZFSsamba/nero

+ getopts R:G:X:B:S:C:U:M:L:H:P:N:Y opt

+ SAMBA_LOGDIR=/ZFSsamba/nero/logs

+ getopts R:G:X:B:S:C:U:M:L:H:P:N:Y opt

+ SAMBA_FMUSER=kfz\\\\fmuser%samba

+ getopts R:G:X:B:S:C:U:M:L:H:P:N:Y opt

+ SAMBA_FMRESOURCE=scmondir

+ getopts R:G:X:B:S:C:U:M:L:H:P:N:Y opt

+ LDPATH=/opt/csw/lib

+ export LD_LIBRARY_PATH=/opt/csw/lib

+ getopts R:G:X:B:S:C:U:M:L:H:P:N:Y opt

+ LHOST=nero-lh1

+ getopts R:G:X:B:S:C:U:M:L:H:P:N:Y opt

+ [ 23 -gt 1 ]

+ CALLER=GDS

+ [ ]

+ shift 22

+ METHOD=start

+ COMPONENT=samba

+ [ GDS = GDS ]

+ [ samba = samba ]

+ [ -z smbd nmbd ]

+ /usr/bin/grep nmbd

+ /usr/bin/echo smbd nmbd

+ 1> /dev/null

+ RUN_NMBD=YES

+ [ start = probe -a samba = samba ]

+ . /opt/SUNWscsmb/bin/../samba/etc/config

+ DEBUG=ALL

+ . /opt/SUNWscsmb/bin/functions

+ PKG=SUNWscsmb

+ + basename /opt/SUNWscsmb/bin/control_samba

MYNAME=control_samba

+ + dirname /opt/SUNWscsmb/bin/control_samba

MYDIR=/opt/SUNWscsmb/bin

+ MYTMPDIR=/var/tmp

+ LOGFILE=/var/tmp/samba-pdc_samba_logfile

+ SCLOGGER=/usr/cluster/lib/sc/scds_syslog

+ LOGGER=/usr/bin/logger

+ NMBD=/opt/csw/sbin/nmbd

+ SMBD=/opt/csw/sbin/smbd

+ NMBLOOKUP=/opt/csw/bin/nmblookup

+ WINBINDD=/opt/csw/sbin/winbindd

+ SMBCONF=/ZFSsamba/nero/lib/smb.conf

+ SMBCLIENT=/opt/csw/bin/smbclient

+ + basename /ZFSsamba/nero

NETBIOSNAME=nero

+ NMBDLOCKF=/ZFSsamba/nero/var/locks/nmbd.pid

+ SMBDLOCKF=/ZFSsamba/nero/var/locks/smbd.pid

+ SAMBA_LOGDIR_TEMP=/ZFSsamba/nero/logs

+ WINBINDLOCKF=/ZFSsamba/nero/var/locks/winbindd.pid

+ NSS=/etc/nsswitch.conf

+ + /usr/sbin/clinfo -n

NODEID_LOCAL=1

+ + expr 1 * 2

STARTWAIT=2

+ TMPF=/var/tmp/nero.tmp

+ [ -x /sbin/zonename ]

+ + /sbin/zonename

ZONENAME=global

+ debug_message Method: control_samba - Begin

+ print SC[SUNWscsmb.samba.start]:samba-rg:samba-pdc

+ set -x

+ validate_common

+ print SC[SUNWscsmb.samba.start]:samba-rg:samba-pdc

+ rc=0

+ [ ! -d /opt/csw/bin ]

+ debug_message Validate - samba bin directory /opt/csw/bin exists

+ print SC[SUNWscsmb.samba.start]:samba-rg:samba-pdc

+ [ ! -d /opt/csw/sbin ]

+ debug_message Validate - samba sbin directory /opt/csw/sbin exists

+ print SC[SUNWscsmb.samba.start]:samba-rg:samba-pdc

+ [ ! -d /ZFSsamba/nero ]

+ debug_message Validate - samba configuration directory /ZFSsamba/nero exists

+ print SC[SUNWscsmb.samba.start]:samba-rg:samba-pdc

+ [ ! -f /ZFSsamba/nero/lib/smb.conf ]

+ debug_message Validate - smbconf /ZFSsamba/nero/lib/smb.conf exists

+ print SC[SUNWscsmb.samba.start]:samba-rg:samba-pdc

+ [ ! -x /opt/csw/bin/nmblookup ]

+ debug_message Validate - nmblookup /opt/csw/bin/nmblookup exists and is executable

+ print SC[SUNWscsmb.samba.start]:samba-rg:samba-pdc

+ /opt/csw/bin/nmblookup -h

+ 1> /dev/null 2>& 1

+ [ 1 -eq 0 ]

+ + /usr/bin/awk {print $2}

+ /opt/csw/bin/nmblookup -V

VERSION=3.0.23b

+ + /usr/bin/cut -d. -f1

+ /usr/bin/echo 3.0.23b

SAMBA_VERSION=3

+ + /usr/bin/cut -d. -f2

+ /usr/bin/echo 3.0.23b

SAMBA_RELEASE=0

+ + /usr/bin/cut -d. -f3

+ /usr/bin/echo 3.0.23b

SAMBA_UPDATE=23b

+ debug_message Validate - Samba version <3.0.23b> is being used

+ print SC[SUNWscsmb.samba.start]:samba-rg:samba-pdc

+ + stripfunc 3

SAMBA_VERSION=3

+ + stripfunc 0

SAMBA_RELEASE=0

+ + stripfunc 23b

SAMBA_UPDATE=23

+ rc_validate_version=0

+ [ -z 3.0.23b ]

+ [ 3 -lt 2 ]

+ [ 3 -eq 2 -a 0 -le 2 -a 23 -lt 2 ]

+ [ 0 -gt 0 ]

+ debug_message Function: validate_common - End

+ print SC[SUNWscsmb.samba.start]:samba-rg:samba-pdc

+ return 0

+ rc1=0

+ validate_samba

+ print SC[SUNWscsmb.samba.start]:samba-rg:samba-pdc

+ rc=0

+ [ ! -d /ZFSsamba/nero/logs ]

+ debug_message Validate - Samba log directory /ZFSsamba/nero/logs exists

+ print SC[SUNWscsmb.samba.start]:samba-rg:samba-pdc

+ [ ! -x /opt/csw/sbin/smbd ]

+ debug_message Validate - smbd /opt/csw/sbin/smbd exists and is executable

+ print SC[SUNWscsmb.samba.start]:samba-rg:samba-pdc

+ [ ! -x /opt/csw/sbin/nmbd ]

+ debug_message Validate - nmbd /opt/csw/sbin/nmbd exists and is executable

+ print SC[SUNWscsmb.samba.start]:samba-rg:samba-pdc

+ /usr/bin/grep scmondir

+ /usr/bin/cut -d] -f1

+ /usr/bin/cut -d[ -f2

+ /usr/bin/grep \[ /ZFSsamba/nero/lib/smb.conf

+ [ -z scmondir ]

+ debug_message Validate - Faultmonitor resource scmondir exists

+ print SC[SUNWscsmb.samba.start]:samba-rg:samba-pdc

+ [ ! -x /opt/csw/bin/smbclient ]

+ debug_message Validate - smbclient /opt/csw/bin/smbclient exists and is executable

+ print SC[SUNWscsmb.samba.start]:samba-rg:samba-pdc

+ + /usr/bin/cut -d% -f1

+ /usr/bin/awk BEGIN { FS="
" } {print $NF}

+ /usr/bin/echo kfz\\\\fmuser%samba

USER=fmuser

+ /usr/bin/getent passwd fmuser

+ [ -z fmuser:x:10000:10000::/home/fmuser: ]

+ debug_message Validate - Retrieved faultmonitor-user fmuser from the nameservice

+ print SC[SUNWscsmb.samba.start]:samba-rg:samba-pdc

+ RUN_NMBD=YES

+ [ YES = YES -o YES = NO ]

+ debug_message Validate - RUN_NMBD=YES

+ print SC[SUNWscsmb.samba.start]:samba-rg:samba-pdc

+ debug_message Function: validate_samba - End

+ print SC[SUNWscsmb.samba.start]:samba-rg:samba-pdc

+ return 0

+ rc2=0

+ rc=1

+ [ 0 -eq 0 -a 0 -eq 0 ]

+ rc=0

+ [ 0 -eq 0 ]

+ start_samba

+ print SC[SUNWscsmb.samba.start]:samba-rg:samba-pdc

+ + /usr/bin/tr -s [:lower:] [:upper:]

+ /usr/bin/tr ,

Fehlerhafte Zeichenkette

+ /usr/bin/echo smbd nmbd

SERVICES=

+ eval ${NMBD} -D -s /ZFSsamba/nero/lib/smb.conf -l /ZFSsamba/nero/logs

+ /opt/csw/sbin/nmbd -D -s /ZFSsamba/nero/lib/smb.conf -l /ZFSsamba/nero/logs

+ rc=0

+ + /usr/bin/tr -s [:upper:] [:lower:]

+ /usr/bin/echo NMBD

Fehlerhafte Zeichenkette

i=

+ [ 0 -eq 0 ]

+ debug_message start_samba - started

+ print SC[SUNWscsmb.samba.start]:samba-rg:samba-pdc

+ eval ${SMBD} -D -s /ZFSsamba/nero/lib/smb.conf -l /ZFSsamba/nero/logs

+ /opt/csw/sbin/smbd -D -s /ZFSsamba/nero/lib/smb.conf -l /ZFSsamba/nero/logs

+ rc=0

+ + /usr/bin/tr -s [:upper:] [:lower:]

+ /usr/bin/echo SMBD

Fehlerhafte Zeichenkette

i=

+ [ 0 -eq 0 ]

+ debug_message start_samba - started

+ print SC[SUNWscsmb.samba.start]:samba-rg:samba-pdc

+ debug_message Function: start_samba - End

+ print SC[SUNWscsmb.samba.start]:samba-rg:samba-pdc

+ return

+ rc=0

+ exit 0

+ rc=0

+ exit 0

jochem_ippersa at 2007-7-10 14:15:00 > top of Java-index,Solaris Operating System,Solaris Essentials - General Technical Questions...
# 8

Hi Jochem,

it seems to be a problem with your localization.

I've got exactly the same problem here with German localization.

If i changed the LC_ALL variable to en_US the script would work fine.

The `tr -s '[:upper:]' '[:lower:]'` command doens't work right with the German locale. Maybe you have to use other options for that.

Best Regards

Alex

Jena, Germany

shakesbeer1000a at 2007-7-10 14:15:00 > top of Java-index,Solaris Operating System,Solaris Essentials - General Technical Questions...
# 9

Hi Alex,

Good catch.

It appears /usr/bin/tr does not have Code Set Intedepdence (CSI) enabled whereas /usr/xpg4/bin/tr does. See the attributes section from the tr(1) man page, i.e.

bash-3.00# locale

LANG=en_GB.ISO8859-15

LC_CTYPE=en_GB.ISO8859-15

LC_NUMERIC=en_GB.ISO8859-15

LC_TIME=en_GB.ISO8859-15

LC_COLLATE=en_GB.ISO8859-15

LC_MONETARY=en_GB.ISO8859-15

LC_MESSAGES=en_GB.ISO8859-15

LC_ALL=

bash-3.00#

bash-3.00# /usr/bin/tr -s '[:lower:]' '[:upper:]'

yes

YES

^C

bash-3.00#

bash-3.00# LC_ALL=de_DE.UTF-8

bash-3.00# export LC_ALL

bash-3.00#

bash-3.00# /usr/bin/tr -s '[:lower:]' '[:upper:]'

Bad string

bash-3.00#

bash-3.00# /usr/xpg4/bin/tr -s '[:lower:]' '[:upper:]'

yes

YES

^C

bash-3.00#

bash-3.00# LC_ALL=de_DE

bash-3.00# export LC_ALL

bash-3.00# /usr/bin/tr -s '[:lower:]' '[:upper:]'

yes

YES

^C

bash-3.00# /usr/xpg4/bin/tr -s '[:lower:]' '[:upper:]'

yes

YES

^C

bash-3.00#

Regards

Neil

neil_garthwaitea at 2007-7-10 14:15:00 > top of Java-index,Solaris Operating System,Solaris Essentials - General Technical Questions...