<?xml version="1.0" encoding="utf-8"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom">
	<channel>
		<atom:link href="http://dev1galaxy.org/extern.php?action=feed&amp;tid=5207&amp;type=rss" rel="self" type="application/rss+xml" />
		<title><![CDATA[Dev1 Galaxy Forum / [SOLVED] lvcreate is not working as expected]]></title>
		<link>http://dev1galaxy.org/viewtopic.php?id=5207</link>
		<description><![CDATA[The most recent posts in [SOLVED] lvcreate is not working as expected.]]></description>
		<lastBuildDate>Thu, 01 Sep 2022 17:27:48 +0000</lastBuildDate>
		<generator>FluxBB</generator>
		<item>
			<title><![CDATA[Re: [SOLVED] lvcreate is not working as expected]]></title>
			<link>http://dev1galaxy.org/viewtopic.php?pid=37289#p37289</link>
			<description><![CDATA[<p>I&#039;ve heard similar anecdotes, and I have bought &quot;refurbished&quot; drives that have had data on them. I have never had that happen with new disks to date.</p><p>For the record, I did not ass-u-me the new disk was blank. I verified it was blank as soon as it was installed and I booted the system. Thanks for the heads up for anyone else reading this though.</p><p>Added: This is a bit of a tangent from the original post we should probably take elsewhere. That said, if your &quot;dead&quot; or used disk has sensitive data on it then have it run through a disk shredder, or otherwise destroy it to the point it is unreadable. If you need to return a defective disk for a replacement, consider not doing that and just buy another new disk and destroy the defective one. These are the only ways to be sure your data on that disk does not escape your control.</p>]]></description>
			<author><![CDATA[dummy@example.com (UnixRocks)]]></author>
			<pubDate>Thu, 01 Sep 2022 17:27:48 +0000</pubDate>
			<guid>http://dev1galaxy.org/viewtopic.php?pid=37289#p37289</guid>
		</item>
		<item>
			<title><![CDATA[Re: [SOLVED] lvcreate is not working as expected]]></title>
			<link>http://dev1galaxy.org/viewtopic.php?pid=37288#p37288</link>
			<description><![CDATA[<div class="quotebox"><cite>UnixRocks wrote:</cite><blockquote><div><p>This is a brand new disk, just taken out of the factory packaging this past weekend. It was completely blank when I added it as a PV then created the VG for the first time and attempted to create the first logical volume on it using the same LVM steps at the CLI I have used hundreds of times in my job as a Unix / Linux administrator at a regional ISP. Since then I have removed all the LVM data and started from a completely blank disk more than once now. There was nothing on the disk to confuse LVM from the start.</p></div></blockquote></div><p>I once overheard one of the LAN admins in our company complaining loudly about a supposedly new disk not being blank (about half of the people in the canteen could hear him). He had spent several hours trying to add the disk to a Novell Netware server and could not get it to work. Eventually he removed all the old disks from the server and booted it with just the new supposedly blank disk in it and it came up as another company&#039;s server!</p><p>So don&#039;t assume a new disk is always blank. Or that a disk you send back as faulty (or part of a faulty system) won&#039;t end up being sold to a random customer. Always wipe anything that might be sensitive first.</p>]]></description>
			<author><![CDATA[dummy@example.com (chris2be8)]]></author>
			<pubDate>Thu, 01 Sep 2022 16:20:50 +0000</pubDate>
			<guid>http://dev1galaxy.org/viewtopic.php?pid=37288#p37288</guid>
		</item>
		<item>
			<title><![CDATA[Re: [SOLVED] lvcreate is not working as expected]]></title>
			<link>http://dev1galaxy.org/viewtopic.php?pid=37284#p37284</link>
			<description><![CDATA[<div class="quotebox"><cite>ralph.ronnquist wrote:</cite><blockquote><div><p>You don&#039;t mention whether(/that?) you also re-created the block device (major:minor = 254:5) as /dev/dm-5?</p></div></blockquote></div><p>The block device was created &quot;automagically&quot; when I used <em>lvcreate</em> with the <em>-Zn</em> switch. Only the symlinks had to be created that first time. I am now happily running with /home, /var, and swap on the new WD 1 TB disk. <img src="http://dev1galaxy.org/img/smilies/smile.png" width="15" height="15" alt="smile" /></p><p>Added: All <em>-Zn</em> does is tell lvcreate to not attempt to zero the new device.</p>]]></description>
			<author><![CDATA[dummy@example.com (UnixRocks)]]></author>
			<pubDate>Wed, 31 Aug 2022 22:07:14 +0000</pubDate>
			<guid>http://dev1galaxy.org/viewtopic.php?pid=37284#p37284</guid>
		</item>
		<item>
			<title><![CDATA[Re: [SOLVED] lvcreate is not working as expected]]></title>
			<link>http://dev1galaxy.org/viewtopic.php?pid=37283#p37283</link>
			<description><![CDATA[<p>You don&#039;t mention whether(/that?) you also re-created the block device (major:minor = 254:5) as /dev/dm-5?</p>]]></description>
			<author><![CDATA[dummy@example.com (ralph.ronnquist)]]></author>
			<pubDate>Wed, 31 Aug 2022 21:46:57 +0000</pubDate>
			<guid>http://dev1galaxy.org/viewtopic.php?pid=37283#p37283</guid>
		</item>
		<item>
			<title><![CDATA[Re: [SOLVED] lvcreate is not working as expected]]></title>
			<link>http://dev1galaxy.org/viewtopic.php?pid=37279#p37279</link>
			<description><![CDATA[<p>To complete this saga, after doing the steps I outlined above and rebooting, when I created my new home logical volume, all the bits were created as expected. I did not have to make any special symlinks. I just had to make the file system with mkfs.ext4, create the new /home2 mount point, mount it, and edit /etc/fstab to make it stick.</p>]]></description>
			<author><![CDATA[dummy@example.com (UnixRocks)]]></author>
			<pubDate>Wed, 31 Aug 2022 20:11:10 +0000</pubDate>
			<guid>http://dev1galaxy.org/viewtopic.php?pid=37279#p37279</guid>
		</item>
		<item>
			<title><![CDATA[Re: [SOLVED] lvcreate is not working as expected]]></title>
			<link>http://dev1galaxy.org/viewtopic.php?pid=37278#p37278</link>
			<description><![CDATA[<p>Yep, it survived a reboot. The steps I outlined above in <a href="https://dev1galaxy.org/viewtopic.php?pid=37275#p37275" rel="nofollow">https://dev1galaxy.org/viewtopic.php?pid=37275#p37275</a> will get one where one needs to be to add a logical volume <strong><em>after</em></strong> using pvcreate and vgcreate.</p><p>Note, this is <strong>not</strong> novice friendly. If <strong>you</strong>, dear reader, are a novice, do not blindly follow my steps. Try to figure out what I did and why first. <img src="http://dev1galaxy.org/img/smilies/wink.png" width="15" height="15" alt="wink" /></p>]]></description>
			<author><![CDATA[dummy@example.com (UnixRocks)]]></author>
			<pubDate>Wed, 31 Aug 2022 19:54:04 +0000</pubDate>
			<guid>http://dev1galaxy.org/viewtopic.php?pid=37278#p37278</guid>
		</item>
		<item>
			<title><![CDATA[Re: [SOLVED] lvcreate is not working as expected]]></title>
			<link>http://dev1galaxy.org/viewtopic.php?pid=37277#p37277</link>
			<description><![CDATA[<div class="quotebox"><cite>rolfie wrote:</cite><blockquote><div><p>There is nothing special with LVM on Devuan. It works fine on my machines. Mostly created while installing the system.</p><p>Here are three links to HowTo&#039;s:<br /><a href="https://tldp.org/HOWTO/LVM-HOWTO/" rel="nofollow">https://tldp.org/HOWTO/LVM-HOWTO/</a><br /><a href="https://linuxhandbook.com/lvm-guide/" rel="nofollow">https://linuxhandbook.com/lvm-guide/</a><br /><a href="https://www.howtoforge.com/linux_lvm" rel="nofollow">https://www.howtoforge.com/linux_lvm</a></p><p>The first I have used a lot.</p></div></blockquote></div><p>I have already been through all the guides, mate. <img src="http://dev1galaxy.org/img/smilies/wink.png" width="15" height="15" alt="wink" /> This problem with lvcreate <strong>AFTER INSTALLATION</strong> is not addressed in any of them. <img src="http://dev1galaxy.org/img/smilies/tongue.png" width="15" height="15" alt="tongue" /> As you can see above, I found a workaround.</p>]]></description>
			<author><![CDATA[dummy@example.com (UnixRocks)]]></author>
			<pubDate>Wed, 31 Aug 2022 19:36:45 +0000</pubDate>
			<guid>http://dev1galaxy.org/viewtopic.php?pid=37277#p37277</guid>
		</item>
		<item>
			<title><![CDATA[Re: [SOLVED] lvcreate is not working as expected]]></title>
			<link>http://dev1galaxy.org/viewtopic.php?pid=37276#p37276</link>
			<description><![CDATA[<p>There is nothing special with LVM on Devuan. It works fine on my machines. Mostly created while installing the system.</p><p>Here are three links to HowTo&#039;s:<br /><a href="https://tldp.org/HOWTO/LVM-HOWTO/" rel="nofollow">https://tldp.org/HOWTO/LVM-HOWTO/</a><br /><a href="https://linuxhandbook.com/lvm-guide/" rel="nofollow">https://linuxhandbook.com/lvm-guide/</a><br /><a href="https://www.howtoforge.com/linux_lvm" rel="nofollow">https://www.howtoforge.com/linux_lvm</a></p><p>The first I have used a lot.</p>]]></description>
			<author><![CDATA[dummy@example.com (rolfie)]]></author>
			<pubDate>Wed, 31 Aug 2022 19:32:01 +0000</pubDate>
			<guid>http://dev1galaxy.org/viewtopic.php?pid=37276#p37276</guid>
		</item>
		<item>
			<title><![CDATA[Re: [SOLVED] lvcreate is not working as expected]]></title>
			<link>http://dev1galaxy.org/viewtopic.php?pid=37275#p37275</link>
			<description><![CDATA[<p>... aaaand I am back to it being a Debian thing: <a href="https://listman.redhat.com/archives/linux-lvm/2015-June/023207.html" rel="nofollow">https://listman.redhat.com/archives/lin … 23207.html</a></p><p>Using the &quot;-Zn&quot; switch worked to partially create what I needed. These steps got my new logical var created and ready to use:</p><div class="codebox"><pre><code>[ROOT@devuan-nuc ~] # lvcreate -Zn -n var -L 20g devuan-nuc-vg2
  WARNING: Logical volume devuan-nuc-vg2/var not zeroed.
  Logical volume &quot;var&quot; created.</code></pre></div><p>Then I ran <em>vgscan --mknodes</em>, but that did not create the symlink in /dev/mapper as I was expecting:</p><div class="codebox"><pre><code>[ROOT@devuan-nuc ~] # ls -l /dev/mapper/
total 0
crw------- 1 root root  10, 236 Aug 30 13:28 control
brw-rw---- 1 root disk 254,   5 Aug 31 11:10 devuan--nuc--vg2-var      &lt;&lt;&lt;--- yeah, no.
lrwxrwxrwx 1 root root        7 Aug 30 05:28 devuan--nuc--vg-home -&gt; ../dm-4
lrwxrwxrwx 1 root root        7 Aug 30 05:28 devuan--nuc--vg-root -&gt; ../dm-0
lrwxrwxrwx 1 root root        7 Aug 30 05:28 devuan--nuc--vg-swap_1 -&gt; ../dm-2
lrwxrwxrwx 1 root root        7 Aug 30 05:28 devuan--nuc--vg-tmp -&gt; ../dm-3
lrwxrwxrwx 1 root root        7 Aug 30 05:28 devuan--nuc--vg-var -&gt; ../dm-1</code></pre></div><p>I removed that file with <em>rm /dev/mapper/devuan--nuc--vg2-var</em>, and created the symlink by hand with:</p><div class="codebox"><pre><code>[ROOT@devuan-nuc ~] # cd /dev/mapper/
[ROOT@devuan-nuc mapper] # ln -s ../dm-5 devuan--nuc--vg2-var</code></pre></div><p>Then I made the filesystem on the logical volume:</p><div class="codebox"><pre><code>[ROOT@devuan-nuc mapper] # mkfs.ext4 /dev/devuan-nuc-vg2/var 
mke2fs 1.46.2 (28-Feb-2021)
Discarding device blocks: done                            
Creating filesystem with 5242880 4k blocks and 1310720 inodes
Filesystem UUID: e46a61e4-c322-4d45-8d26-31386bd47efb
Superblock backups stored on blocks: 
	32768, 98304, 163840, 229376, 294912, 819200, 884736, 1605632, 2654208, 
	4096000

Allocating group tables: done                            
Writing inode tables: done                            
Creating journal (32768 blocks): done
Writing superblocks and filesystem accounting information: done </code></pre></div><p>Now I will make a mount point, mount the sucker, add that to /etc/fstab, and see if this all survives a reboot or not.</p>]]></description>
			<author><![CDATA[dummy@example.com (UnixRocks)]]></author>
			<pubDate>Wed, 31 Aug 2022 19:31:56 +0000</pubDate>
			<guid>http://dev1galaxy.org/viewtopic.php?pid=37275#p37275</guid>
		</item>
		<item>
			<title><![CDATA[Re: [SOLVED] lvcreate is not working as expected]]></title>
			<link>http://dev1galaxy.org/viewtopic.php?pid=37274#p37274</link>
			<description><![CDATA[<p>Huh, interesting. I am web searching to find out how to make the LVM stuff work on Devuan. Look at &quot;Never use ...&quot; under the <strong>Notes</strong> section on this page: <a href="https://www.thegeekdiary.com/how-to-create-partitions-and-file-systems-on-dm-multipath-devices/" rel="nofollow">https://www.thegeekdiary.com/how-to-cre … h-devices/</a></p><p>Yet those are used when logical volumes are made using the Devuan installer. Weird. <img src="http://dev1galaxy.org/img/smilies/hmm.png" width="15" height="15" alt="hmm" /></p>]]></description>
			<author><![CDATA[dummy@example.com (UnixRocks)]]></author>
			<pubDate>Wed, 31 Aug 2022 18:39:42 +0000</pubDate>
			<guid>http://dev1galaxy.org/viewtopic.php?pid=37274#p37274</guid>
		</item>
		<item>
			<title><![CDATA[Re: [SOLVED] lvcreate is not working as expected]]></title>
			<link>http://dev1galaxy.org/viewtopic.php?pid=37273#p37273</link>
			<description><![CDATA[<p>I wonder why there is no new volume group directory, nor dm-? file created for this attempt at making a new logical volume? I see these for the original install:</p><div class="codebox"><pre><code>[ROOT@devuan-nuc ~] # ls -dl /dev/devuan-nuc-vg*
drwxr-xr-x 2 root root 140 Aug 30 05:28 /dev/devuan-nuc-vg

[ROOT@devuan-nuc ~] # ls -l /dev/devuan-nuc-vg*
total 0
lrwxrwxrwx 1 root root 7 Aug 30 05:28 home -&gt; ../dm-4
lrwxrwxrwx 1 root root 7 Aug 30 05:28 root -&gt; ../dm-0
lrwxrwxrwx 1 root root 7 Aug 30 05:28 swap_1 -&gt; ../dm-2
lrwxrwxrwx 1 root root 7 Aug 30 05:28 tmp -&gt; ../dm-3
lrwxrwxrwx 1 root root 7 Aug 30 05:28 var -&gt; ../dm-1

[ROOT@devuan-nuc ~] # ls -l /dev/dm*
brw-rw---- 1 root disk 254, 0 Aug 30 13:28 /dev/dm-0
brw-rw---- 1 root disk 254, 1 Aug 30 13:28 /dev/dm-1
brw-rw---- 1 root disk 254, 2 Aug 30 13:28 /dev/dm-2
brw-rw---- 1 root disk 254, 3 Aug 30 13:28 /dev/dm-3
brw-rw---- 1 root disk 254, 4 Aug 30 13:28 /dev/dm-4</code></pre></div><p>There should be a /dev/devuan-nuc-vg2 directory for the new volume group. It seems there should also be a /dev/dm-5(?) created when I make the new logical volume. I have never had to create any of that stuff by hand, but if needed, I will do it. Anyone here know the proper method to get those created?</p><p>Added: Obviously I can create the directory and symlinks &quot;by hand&quot; with mkdir and ln. My main concern is getting the dm-? disk files created correctly.</p>]]></description>
			<author><![CDATA[dummy@example.com (UnixRocks)]]></author>
			<pubDate>Wed, 31 Aug 2022 17:55:38 +0000</pubDate>
			<guid>http://dev1galaxy.org/viewtopic.php?pid=37273#p37273</guid>
		</item>
		<item>
			<title><![CDATA[Re: [SOLVED] lvcreate is not working as expected]]></title>
			<link>http://dev1galaxy.org/viewtopic.php?pid=37268#p37268</link>
			<description><![CDATA[<p>Yeah, I&#039;m off down the wrong rabbit hole with the #PV thing. <img src="http://dev1galaxy.org/img/smilies/hmm.png" width="15" height="15" alt="hmm" /></p><p>This is my home system. I cannot copy files from the work systems to my home, nor vice versa, for diff without breaking company security rules. Besides, I am on vacation from work which is why I have time to work on my home setup. Not gonna login to work just for this. Someone would notice, and I would get pinged for workthing. <img src="http://dev1galaxy.org/img/smilies/wink.png" width="15" height="15" alt="wink" /></p><p>I can take a gander at the work systems when I am back at work next week to see if I can find a difference with my eyeball-mark-I.</p>]]></description>
			<author><![CDATA[dummy@example.com (UnixRocks)]]></author>
			<pubDate>Wed, 31 Aug 2022 02:20:41 +0000</pubDate>
			<guid>http://dev1galaxy.org/viewtopic.php?pid=37268#p37268</guid>
		</item>
		<item>
			<title><![CDATA[Re: [SOLVED] lvcreate is not working as expected]]></title>
			<link>http://dev1galaxy.org/viewtopic.php?pid=37267#p37267</link>
			<description><![CDATA[<p>Isn&#039;t the <span class="bbc">#PV</span> just a counter?</p><p>If there is a difference between Devuan/Debian and those other OS types, it might be a difference in the <span class="bbc">lvm.conf</span> files. Perhaps you can diff those between systems?</p>]]></description>
			<author><![CDATA[dummy@example.com (ralph.ronnquist)]]></author>
			<pubDate>Wed, 31 Aug 2022 00:40:24 +0000</pubDate>
			<guid>http://dev1galaxy.org/viewtopic.php?pid=37267#p37267</guid>
		</item>
		<item>
			<title><![CDATA[Re: [SOLVED] lvcreate is not working as expected]]></title>
			<link>http://dev1galaxy.org/viewtopic.php?pid=37266#p37266</link>
			<description><![CDATA[<p>Okay, this vgs output looks weird:</p><div class="codebox"><pre><code>[ROOT@devuan-nuc ~] # vgs
  VG             #PV #LV #SN Attr   VSize    VFree  
  devuan-nuc-vg    1   5   0 wz--n- &lt;222.59g  12.00m
  devuan-nuc-vg2   1   0   0 wz--n-  931.51g 931.51</code></pre></div><p>Why are both showing up as on PV 1? There are TWO physical disks:</p><div class="codebox"><pre><code>[ROOT@devuan-nuc ~] # pvs
  PV         VG             Fmt  Attr PSize    PFree  
  /dev/sda3  devuan-nuc-vg  lvm2 a--  &lt;222.59g  12.00m
  /dev/sdb   devuan-nuc-vg2 lvm2 a--   931.51g 931.51g</code></pre></div><p>Or am I misreading that? At this point I am fairly confused. <img src="http://dev1galaxy.org/img/smilies/sad.png" width="15" height="15" alt="sad" /></p>]]></description>
			<author><![CDATA[dummy@example.com (UnixRocks)]]></author>
			<pubDate>Wed, 31 Aug 2022 00:22:23 +0000</pubDate>
			<guid>http://dev1galaxy.org/viewtopic.php?pid=37266#p37266</guid>
		</item>
		<item>
			<title><![CDATA[Re: [SOLVED] lvcreate is not working as expected]]></title>
			<link>http://dev1galaxy.org/viewtopic.php?pid=37265#p37265</link>
			<description><![CDATA[<p>Thank you for your suggestions.</p><p>This is a brand new disk, just taken out of the factory packaging this past weekend. It was completely blank when I added it as a PV then created the VG for the first time and attempted to create the first logical volume on it using the same LVM steps at the CLI I have used hundreds of times in my job as a Unix / Linux administrator at a regional ISP. Since then I have removed all the LVM data and started from a completely blank disk more than once now. There was nothing on the disk to confuse LVM from the start.</p><p>That said, my company uses primarily Red Hat / CentOS (ICK!). So I suspect there is a difference between those and Devuan / Debian that I am missing.</p>]]></description>
			<author><![CDATA[dummy@example.com (UnixRocks)]]></author>
			<pubDate>Tue, 30 Aug 2022 23:59:26 +0000</pubDate>
			<guid>http://dev1galaxy.org/viewtopic.php?pid=37265#p37265</guid>
		</item>
	</channel>
</rss>
