Clear doesn't have this run by default. You could try making a service
(Type=oneshot) to run the device scan and make the mount unit require
that service and see if that gets the uuid detection.
On Mon, Nov 20, 2017 at 3:16 PM, Richard Thornton
<richie.thornton(a)gmail.com> wrote:
How does CL implement the btrfs device scan?
https://btrfs.wiki.kernel.org/index.php/Problem_FAQ
Then you need to ensure that you run a btrfs device scan first:
# btrfs device scan
This should be in many distributions' startup scripts (and initrd
images, if your root filesystem is btrfs), but you may have to add it
yourself.
On 21 November 2017 at 10:09, Richard Thornton
<richie.thornton(a)gmail.com> wrote:
> I can see:
>
> [ 20.062217] mpt2sas_cm0: LSISAS2008: FWVersion(07.15.04.00),
> ChipRevision(0x03), BiosVersion(00.00.00.00)
> ...
> [ 20.198645] Btrfs loaded, crc32c=crc32c-intel
> ...
> [ 30.073488] BTRFS: device fsid a4d1ef9d-e75f-41dd-acac-9aaa79428965
> devid 2 transid 16 /dev/sdb
> [ 30.073911] BTRFS info (device sdb): disk space caching is enabled
> [ 30.073912] BTRFS info (device sdb): has skinny extents
> [ 30.074170] BTRFS warning (device sdb): devid 1 uuid
> fc680ff9-c623-4baf-85d4-c634d2dbc6ef is missing
> [ 30.074171] BTRFS error (device sdb): failed to read the system array: -5
> [ 30.101015] BTRFS error (device sdb): open_ctree failed
>
> It's interesting that it finds "devid 2" but errors on "devid
1" missing?
>
> On 21 November 2017 at 08:54, Richard Thornton
> <richie.thornton(a)gmail.com> wrote:
>> Thanks, what would be the preferred way to do this after the CL system had
>> booted:
>>
>> Start mount
>> Start nmbd
>> Start Smdb
>> Start docker (plex)
>>
>>
>> On 21 Nov. 2017 08:25, "Douglas, William"
<william.douglas(a)intel.com> wrote:
>>
>> You might be seeing an instance where /dev/disk/by-uuid is not fully
>> populated by the time your service runs. Having your disk attached to
>> an adapter makes this more likely to me.
>>
>> Maybe try
>>
https://www.freedesktop.org/software/systemd/man/systemd.mount.html#Timeo...
>> but that's just for the mount command so I'm not sure if it will even
>> attempt to run the mount or not based on the uuid missing log you had
>> but that's the only thing I could find that might work.
>>
>> On Mon, Nov 20, 2017 at 1:08 PM, Richard Thornton
>> <richie.thornton(a)gmail.com> wrote:
>>> I should add that the btrfs disks are attached to an LSI pcie adapter.
>>>
>>> On 21 Nov. 2017 07:56, "Richard Thornton"
<richie.thornton(a)gmail.com>
>>> wrote:
>>>>
>>>> My dir:
>>>>
>>>> root@thor ~ # ls /etc/systemd/system/
>>>>
>>>> multi-user.target.wants nmbd.service smbd.service storage.mount
>>>>
>>>> On 21 November 2017 at 07:42, Richard Thornton
>>>> <richie.thornton(a)gmail.com> wrote:
>>>> > dmesg snippet:
>>>> >
>>>> > [ 30.073488] BTRFS: device fsid
a4d1ef9d-e75f-41dd-acac-9aaa79428965
>>>> > devid 2 transid 16 /dev/sdb
>>>> > [ 30.073911] BTRFS info (device sdb): disk space caching is
enabled
>>>> > [ 30.073912] BTRFS info (device sdb): has skinny extents
>>>> > [ 30.074170] BTRFS warning (device sdb): devid 1 uuid
>>>> > fc680ff9-c623-4baf-85d4-c634d2dbc6ef is missing
>>>> > [ 30.074171] BTRFS error (device sdb): failed to read the system
>>>> > array: -5
>>>> > [ 30.101015] BTRFS error (device sdb): open_ctree failed
>>>> >
>>>> > On 21 November 2017 at 07:21, Richard Thornton
>>>> > <richie.thornton(a)gmail.com> wrote:
>>>> >> Thanks, the below works with "systemctl start
storage.mount" but not
>>>> >> when enabled for boot:
>>>> >>
>>>> >> [Unit]
>>>> >> Description=Mount
>>>> >> Before=nmbd.service
>>>> >>
>>>> >> [Mount]
>>>> >> What=/dev/disk/by-uuid/a4d1ef9d-e75f-41dd-acac-9aaa79428965
>>>> >> Where=/storage
>>>> >>
>>>> >> [Install]
>>>> >> WantedBy=multi-user.target
>>>> >>
>>>> >> On 21 November 2017 at 06:04, Douglas, William
>>>> >> <william.douglas(a)intel.com> wrote:
>>>> >>> So I didn't see any issues when I did this. Can you show
the
>>>> >>> storage.mount file and tell me what is the target that
requires
>>>> >>> storage.mount?
>>>> >>>
>>>> >>> On Mon, Nov 20, 2017 at 8:49 AM, Douglas, William
>>>> >>> <william.douglas(a)intel.com> wrote:
>>>> >>>> I haven't tried this recently so I'll give it a
go today and get
>>>> >>>> back
>>>> >>>> to
>>>> >>>> you.
>>>> >>>>
>>>> >>>>
>>>> >>>> On Nov 20, 2017 02:45, "Richard Thornton"
>>>> >>>> <richie.thornton(a)gmail.com>
>>>> >>>> wrote:
>>>> >>>>
>>>> >>>> Thanks, I finally got around to setting this up, systemd
is loading
>>>> >>>> samba on boot and I could mount btrfs with
>>>> >>>> "systemctl start storage.mount" after boot.
>>>> >>>>
>>>> >>>> The issue I'm having is I can't get a btrfs to
mount on boot, I
>>>> >>>> tried
>>>> >>>> systemd and fstab. I think it could be something to do
with this:
>>>> >>>>
>>>> >>>>
>>>> >>>>
>>>> >>>>
https://blogs.gentoo.org/remi/2014/12/05/gentoo-btrfs-arrays-and-systemd-...
>>>> >>>>
>>>> >>>> I spent hours on trying to get this to persistent mount,
including
>>>> >>>> doing what the above link stated, can someone please
help me out?
>>>> >>>>
>>>> >>>> Thanks.
>>>> >>>>
>>>> >>>> Richard
>>>> >>>>
>>>> >>>> On 20 October 2017 at 02:19, Nesius, Robert A
>>>> >>>> <robert.a.nesius(a)intel.com>
>>>> >>>> wrote:
>>>> >>>>> Yep - you got it.
>>>> >>>>>
>>>> >>>>> Technically systemd supports /etc/fstab for
backwards compatibility
>>>> >>>>> - it
>>>> >>>>> generates a mount unit for each line in the file.
>>>> >>>>>
>>>> >>>>> -Rob
>>>> >>>>>
>>>> >>>>> Sent from mobile device.
>>>> >>>>>
>>>> >>>>> On Oct 18, 2017, at 9:03 PM, Richard Thornton
>>>> >>>>> <richie.thornton(a)gmail.com>
>>>> >>>>> wrote:
>>>> >>>>>
>>>> >>>>> Hi,
>>>> >>>>>
>>>> >>>>> Sorry to bother you all.
>>>> >>>>>
>>>> >>>>> I like Clear Linux a lot and Arjan has been a great
help.
>>>> >>>>>
>>>> >>>>> Posted to dev@ because I couldn't see a user@
>>>> >>>>>
>>>> >>>>> I'm going to use Clear Linux for a 24/7 home
server, I like the
>>>> >>>>> upgrade system (used to use Ubuntu).
>>>> >>>>>
>>>> >>>>> I'm going to use Docker containers for my
applications.
>>>> >>>>>
>>>> >>>>> I want to setup some persistence, if there is a
reboot I would like
>>>> >>>>> my
>>>> >>>>> storage disks to mount, Samba to start and my Docker
containers to
>>>> >>>>> run.
>>>> >>>>>
>>>> >>>>> I think the way to do this is through systemd on CL,
if so, I need
>>>> >>>>> to
>>>> >>>>> create the /etc/systemd structure?
>>>> >>>>>
>>>> >>>>> Just looking for best practices, advice and any
documentation that
>>>> >>>>> may
>>>> >>>>> be out there.
>>>> >>>>>
>>>> >>>>> Thanks.
>>>> >>>>>
>>>> >>>>> Richard
>>>> >>>>> _______________________________________________
>>>> >>>>> Dev mailing list
>>>> >>>>> Dev(a)lists.clearlinux.org
>>>> >>>>>
https://lists.clearlinux.org/mailman/listinfo/dev
>>>> >>>> _______________________________________________
>>>> >>>> Dev mailing list
>>>> >>>> Dev(a)lists.clearlinux.org
>>>> >>>>
https://lists.clearlinux.org/mailman/listinfo/dev
>>>> >>>>
>>>> >>>>
>>
>>