Alastair_Gordon wrote:
From SSH I can see that the “smbd” process runs briefly whenever the drive is accessed via its drive letter in Windows Explorer, but immediately goes away. I think if anything on the LAN was accessing the My Cloud, that “smbd” would be running. Am I wrong about that?
At least one smbd should be running at all times – even if nothing is connected, because there must be one process running to handle incoming NEW connections.
When an active connection (for example, a file open) is created, another smbd process can be spawned to service that request.
CloudNAS:~# ps aux | grep smb
root 5656 0.0 0.3 8568 828 ? Ss Jan07 1:27 /usr/sbin/smbd -D
root 5727 0.0 0.3 9064 896 ? S Jan07 0:04 /usr/sbin/smbd -D
root 18355 0.0 0.3 8568 800 ? S 14:10 0:00 /usr/sbin/smbd -D
root 18400 0.0 0.2 1604 560 pts/0 S+ 14:10 0:00 grep smb
root 27132 0.0 0.9 14716 2080 ? S Jan19 0:06 /usr/sbin/smbd -D
CloudNAS:~# cat /proc/5656/status | grep -i ppid
PPid: 1
CloudNAS:~# cat /proc/5727/status | grep -i ppid
PPid: 5656
CloudNAS:~#
At the time I executed that command, there were four SMB daemons running.
Since process 5656 has a “PPid” of 1, that’s the one that runs forever. (It was spawned by the parent process “init,” which is the ultimate parent of everything)
Process 5727, as you see, has parent 5656 which is the “main” SMB daemon above.
Unplugging the network cable has odd consequences. Unplugging the cable causes several errors, so it will probably spin up the disk to load up the error handling scripts which send e-mail notifications, changes the Web UI, etc.
It probably will continue to run because it can’t get anything out, but I’ve never tried that myself…
Looking at my log files, it looks like it’s about 10 minutes for it to go into standby…
Here’s today’s log so far:
Jan 24 03:00:08 CloudNAS logger: exit standby after 20189 (since 2014-01-23 21:23:39.305480001 -0600)
Jan 24 03:16:26 CloudNAS logger: exit standby after 314 (since 2014-01-24 03:11:12.047114001 -0600)
Jan 24 03:42:37 CloudNAS logger: exit standby after 967 (since 2014-01-24 03:26:30.867114001 -0600)
Jan 24 03:55:08 CloudNAS logger: exit standby after 146 (since 2014-01-24 03:52:42.187114001 -0600)
Jan 24 04:24:32 CloudNAS logger: exit standby after 1160 (since 2014-01-24 04:05:12.727114001 -0600)
Jan 24 06:54:35 CloudNAS logger: exit standby after 8399 (since 2014-01-24 04:34:36.907114001 -0600)
Jan 24 07:45:17 CloudNAS logger: exit standby after 1346 (since 2014-01-24 07:22:51.887114001 -0600)
Jan 24 07:57:30 CloudNAS logger: exit standby after 7 (since 2014-01-24 07:57:23.477114001 -0600)
Jan 24 08:09:14 CloudNAS logger: exit standby after 99 (since 2014-01-24 08:07:35.477114001 -0600)
Jan 24 08:23:46 CloudNAS logger: exit standby after 267 (since 2014-01-24 08:19:19.077114001 -0600)
Jan 24 08:34:11 CloudNAS logger: exit standby after 21 (since 2014-01-24 08:33:50.767114001 -0600)
Jan 24 08:52:45 CloudNAS logger: exit standby after 509 (since 2014-01-24 08:44:16.377114001 -0600)
Jan 24 09:05:08 CloudNAS logger: exit standby after 138 (since 2014-01-24 09:02:50.567114001 -0600)
Jan 24 09:15:54 CloudNAS logger: exit standby after 41 (since 2014-01-24 09:15:13.467114001 -0600)
Jan 24 09:26:24 CloudNAS logger: exit standby after 26 (since 2014-01-24 09:25:58.937114001 -0600)
Jan 24 09:38:13 CloudNAS logger: exit standby after 104 (since 2014-01-24 09:36:29.227114001 -0600)
Jan 24 09:48:56 CloudNAS logger: exit standby after 38 (since 2014-01-24 09:48:18.577114001 -0600)
Jan 24 10:20:41 CloudNAS logger: exit standby after 1299 (since 2014-01-24 09:59:01.997114001 -0600)
Jan 24 10:53:11 CloudNAS logger: exit standby after 1345 (since 2014-01-24 10:30:46.597114001 -0600)
Jan 24 11:11:01 CloudNAS logger: exit standby after 465 (since 2014-01-24 11:03:16.337114001 -0600)
Jan 24 11:39:02 CloudNAS logger: exit standby after 1076 (since 2014-01-24 11:21:06.257114001 -0600)
Jan 24 11:55:08 CloudNAS logger: exit standby after 362 (since 2014-01-24 11:49:06.827114001 -0600)
Jan 24 12:34:55 CloudNAS logger: exit standby after 1783 (since 2014-01-24 12:05:12.707114001 -0600)
Jan 24 13:05:46 CloudNAS logger: exit standby after 1246 (since 2014-01-24 12:45:00.087114001 -0600)
Jan 24 14:08:17 CloudNAS logger: exit standby after 3146 (since 2014-01-24 13:15:51.127114001 -0600)
Jan 24 14:27:21 CloudNAS logger: exit standby after 236 (since 2014-01-24 14:23:24.447114001 -0600)
So today, it’s gone to sleep 25 times Heck. Just noticed it went to sleep while I was logged in via SSH even… (That very last line…)
That very first line says that until 3:00AM (when CRON jobs start) the NAS had been peacefully sleeping since 9:23PM last night.