Jump to content

Recommended Posts

Posted

Trouble setting up lvm2. vgcreate wrong because drive order is not now the plugin order on hub according to dmeg. interchanged cables vs ports for out of order discovery and rebooted but problem unchanged ack dmesg.  So how do I blow away the volume_group that does not get made due to this error, so I can re vgcreate a new lvm? An hour later, I have tried, rearranging cable vs ports on the hub but the rusty drive stays at /dev/sdd# when it was /dev/sdf# b4 everything was partitioned.  What the heck is going on?  For this to stand a snow balls chance in hell of working, I MUST have stable drive id's.  Can vgcreate use PARTUUID's instead of /dev/sda /dev/sdb etc as identifiers?

 

Thank you, Gene1934

 

Thank you.

Posted
vor einer Stunde schrieb gene1934:

What the heck is going on?  For this to stand a snow balls chance in hell of working, I MUST have stable drive id's.

You can't be sure, that's for sure.

Before vgcreate there is pvcreate, and id/labeling is one approach to deal with changing boot orders.

Posted
1 hour ago, gene1934 said:

I MUST have stable drive id's. 

Have a look in /dev/disk/

You can use the 'by-id'  symbolic links normally to identify the storage devices exactly.

Posted

1TB toshiba drive arrived & installed. Too much startup current for hub, hub shuts down instantly and in 3 powerdown reboots, no drives detected. unplugged last 2 drives leaving 4 plugged in, all 4 left plugged in, sda, sdb, sdc, sdd found ok. so an almost $40 Hub is piece of excrement. Do you know of a 7 port usb3.2 hub that can handle 6 drives? Ought to survive 5 amps per port used current. Or maybe good enough since I still have 2 open usb ports on the bpi-m5, and another hub just like this piece of shit, but I'll have to print another mount for the second hub. That will take a couple days as I'll have to give shoe-goo a chance to cure  in addition to reworking another psu cord for the hub. And find another 1 foot std usb cable.

Might spread it's drive tree out to 3 loads per hub to equalize and reduce the individual hub load. So I'm off to print the mount for a 2nd hub. Probably back later. These are all like tires I haven't kicked, yet. ;o)>

 

At what stage in the setup do I apply a label to the drive so it survives the LVM configuration/creation?

It would be a much shorter list to build if disk labels could be used.

 

Thank you. Gene Heskett, old (90) retired CET.

Posted

I'm not out of the woods yet. I installed a bigger cache drive and its startup current kills the hub all this is plugged into, so ATM I'm in the process of mounting a 2nd fast hub to split the current up into something these funkity hubs can handle w/o shutdowns. With glue curing times, about another 36 hours to know if that is the fix.

Posted

I think I've found a bug. I've now installed a 2nd Hub to spread the load to 3 drives a hub.A full powerdown reboot now finds the drives, at stable but odd addrresses but a reboot as root misses both hubs and finds nothing. 100% Repeatable.  3 drives plugged into each hub. So the load currants s/b under the hubs protective tripoff point. PSU is good for 20 amps.

Hubs are identical, Chinese Achoro 7 port, all ports rated for usb-3.2 traffic.  Works from powerup, fails for reboot. I think 

i'm in deeper than my IQ expected Why?

 

Cheers, Gene1934, a CET back in $DAYJOB time.

Posted
12 hours ago, gene1934 said:

Do you know of a 7 port usb3.2 hub that can handle 6 drives? Ought to survive 5 amps per port used current.

Maybe others know, but I stopped buying and using USB cabling and hubs for storage/NAS solutions more than a decade ago, except that unfortunately for RaspberryPi4 I had a Samsung 840 Evo 256GB reserved form an older PC. Raspberries only have USB so you cannot use dedicated normal storage I/O protocols like SATA and NVME. Only way to not let it crash every now and then is a USB adaptor cable with ASMedia chipset (not JMicron at least) and own dedicated externally powered USB3 hub. I use 4-port RSTECH with a 2A adaptor, it prevents back feeding 5V from the adaptor to the Pi at reboots and shutdown. 

If it is all only 5V, assume max 3A for the whole setup, else you need to study your power tree setup. And solder DC/DC converters etc yourself or indeed look for USB hubs that don't exist. USB2 is 0.5 Amps per port, 10x as much you only get when there is special chips and negotiation in the USB-C cables that allow switching from 3A to 5A and also switching from 5v to 9v or 12v or 15v or 20v. 

 

I went back to what I did 2 decades ago for PC NAS: SATA and 12V (for a large 3.5 inch HDD).  I use a 12V 10A powerbrick, but also enough old and good unused PC PSU units that can do many Amps on 12V and I believe 1 PSU can do 40 Amps on 5V. They have a fan, that is why I do not use them. I use a car battery as UPS.

 

Swapping /dev/sdX names is also often a sign of power problems so USB storage disappears but the kernel still uses a particular /dev/sdX. In mutli-device setups, it is a receipt for disaster mostly (corrupt filesystem). 

Posted

I might have bypassed the bug, I partitioned and formatted the 1T toshiba and it has now rebooted fully 2 times.

And I have configured a vgroup labeled "amtapes".  So what next, it (amtapes) is not visible in /dev yet so can't be mounted for use.

Posted

now I must confess this is not on armbian, but on debian image, and at 6.1.4, in the above link. the mkfs.gfs2 is command not found. and apt can't find it either, so I seem to be missing a pkg. What main pkg would I install to get it?

Posted (edited)

gfs2-utils
 

But it looks like you want to share storage. You do not need a GFS2 system for that, but a regular Linux filesystem and a NFS server or SMB server for sharing over the network.

 

Most people will use Ext4 or Btrfs or XFS in Linux.

Edited by eselarm
Posted

I expect I have royally  screwed it up but i have something mounted as /dm-0 that looks like 1% of what I expected. And I have forgotten the shell command that reports the size and % used of a mounted filesystem. Ahh, df and its report says I've created /dev/dm-0 on the 128G u-sd it boots from.  So I apparently need to delete /dev/amtapes which is a link to new_volume_group which points to /dev/dm-0 and start all over again. How do I do that? I'd kill for a man page that actually explained this.  An endless list of options but no defaults.

 

Currently I think I have this:

root@amanda:/# pvscan
  PV /dev/sda1   VG amtapes         lvm2 [<3.34 TiB / <3.34 TiB free]
  PV /dev/sdc1   VG amtapes         lvm2 [<3.34 TiB / <3.34 TiB free]
  PV /dev/sdd1   VG amtapes         lvm2 [<3.34 TiB / <3.34 TiB free]
  PV /dev/sde1   VG amtapes         lvm2 [<3.34 TiB / <3.34 TiB free]
  PV /dev/sdf1   VG amtapes         lvm2 [<3.34 TiB / <3.34 TiB free]
  Total: 5 [<16.69 TiB] / in use: 5 [<16.69 TiB] / in no VG: 0 [0   ]

But might need to recreate it from empty space now. I do know how to blank the drives.

Posted

ok, i blew away the amtapes  VG and recreated a "myvg" using the same PV list. Doesn't show except in vgscan, where it reports this:

root@amanda:/# vgscan
  Found volume group "myvg" using metadata type lvm2

I've played the 10,000 monkeys scene with lvcreate but have only gotten errors. systemctl daemon-reload takes most of a second but /dev remains empty of any sign of something I can mount and run df on.

root@amanda:/# vgs
  VG   #PV #LV #SN Attr   VSize   VFree  
  myvg   5   0   0 wz--n- <16.69t <16.69t
 

Now, following the redhat link many posts above I get to mkfs.ext4 dm-0 and it claims zero capacity.

root@amanda:~# mount -text4 /dev/dm-0 /dm-0
mount: /dm-0: wrong fs type, bad option, bad superblock on /dev/mapper/myvg-dm--0, missing codepage or helper program, or other error.
       dmesg(1) may have more information after failed mount system call.
dmesg says:EXT4-fs (dm-0): VFS: Can't find ext4 filesystem

Thank you for any clarification, gene1934

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
×
×
  • Create New...

Important Information

Terms of Use - Privacy Policy - Guidelines