<?xml version="1.0" encoding="utf-8"?>
<?xml-stylesheet type="text/xsl" href="../assets/xml/rss.xsl" media="all"?><rss version="2.0" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:atom="http://www.w3.org/2005/Atom"><channel><title>Stefano Rivera (Posts about bug)</title><link>https://stefanorivera.com/</link><description></description><atom:link href="https://stefanorivera.com/categories/bug.xml" rel="self" type="application/rss+xml"></atom:link><language>en</language><copyright>Contents © 2025 &lt;a href="mailto:stefano@rivera.za.net"&gt;Stefano Rivera&lt;/a&gt; 
&lt;a rel="license" href="https://creativecommons.org/licenses/by-sa/4.0/"&gt;
&lt;img alt="Creative Commons License BY-SA"
     class="cc-license-button"
     src="/assets/img/cc-by-sa-4.0.svg"&gt;&lt;/a&gt;</copyright><lastBuildDate>Mon, 10 Nov 2025 10:14:04 GMT</lastBuildDate><generator>Nikola (getnikola.com)</generator><docs>http://blogs.law.harvard.edu/tech/rss</docs><item><title>Just what is Universally Unique</title><link>https://stefanorivera.com/posts/2008/02/16/just-what-universally-unique/</link><dc:creator>Stefano Rivera</dc:creator><description>&lt;p&gt;I had an interesting discussion with "bonnyrsa" in #ubuntu-za today. He'd re-arranged his partitions with gparted, and copied and pasted his / partition, so that he could move it to the end of the disk.&lt;/p&gt;
&lt;p&gt;However this meant that he now had two partitions with the same &lt;a href="https://en.wikipedia.org/wiki/UUID"&gt;UUID&lt;/a&gt;. While you can imagine that this is the correct result of a copy &amp;amp; paste operation, it now means that your &lt;em&gt;universally unique&lt;/em&gt; ID is totally non-unique. Not in your PC, and no even on it's home drive.&lt;/p&gt;
&lt;p&gt;Ubuntu mounts by UUID, so now how do we know which partition is being mounted?&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;"mount" said /dev/sda2&lt;/li&gt;
&lt;li&gt;/proc/mounts said /dev/disk/by-uuid/c087bad7-5021-4f65-bb97-e0d3ea9d01a6 which was a symlink to /dev/sda2.&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;However neither were correct.&lt;/p&gt;
&lt;p&gt;Mounting /dev/sda4 (ro) produced "/dev/sda4 already mounted or /mnt busy".&lt;/p&gt;
&lt;p&gt;Aha, so we must be running from /dev/sda4.&lt;/p&gt;
&lt;p&gt;/dev/sda2 mounted fine, but then wouldn't unmount: "it seems /dev/sda2 is mounted multiple times".&lt;/p&gt;
&lt;p&gt;Aaaargh!&lt;/p&gt;
&lt;p&gt;I got him to reboot, change /dev/sda2s UUID, and reboot again (sucks). Then everything was better.&lt;/p&gt;
&lt;p&gt;This shouldn't have happened. Non-unique UUIDs is a really crap situation to be in. It brings out bugs in all sorts of unexpected places. I think parted should (by default) change the UUID of a copied partition (although if you are copying an entire disk, it shouldn't).&lt;/p&gt;
&lt;p&gt;I've filed a &lt;a href="https://bugs.launchpad.net/bugs/192471"&gt;bug&lt;/a&gt; on Launchpad, let's see if anyone bites.&lt;/p&gt;
&lt;p&gt;PS: All UUIDs in this post have been changed to protect the identity of innocent Ubuntu systems (who aren't expecting a sudden attack of non-uniqueness).&lt;/p&gt;</description><category>bug</category><category>linux</category><category>technical</category><category>ubuntu</category><guid>http://tumbleweed.org.za/2008/02/16/just-what-universally-unique</guid><pubDate>Sat, 16 Feb 2008 20:31:25 GMT</pubDate></item></channel></rss>