<?xml version="1.0" encoding="UTF-8"?>        <rss version="2.0"
             xmlns:atom="http://www.w3.org/2005/Atom"
             xmlns:dc="http://purl.org/dc/elements/1.1/"
             xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
             xmlns:admin="http://webns.net/mvcb/"
             xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
             xmlns:content="http://purl.org/rss/1.0/modules/content/">
        <channel>
            <title>
									QNAP - SSH - Manually rebuild &quot;inactive volume&quot; (some useful commands) - QNAP NAS				            </title>
            <link>https://www.tweaking4all.com/forum/qnap-nas/qnap-ssh-manually-rebuild-inactive-volume-some-useful-commands/</link>
            <description>Tweaking4All.com Discussion Board</description>
            <language>en-US</language>
            <lastBuildDate>Wed, 15 Jul 2026 19:23:15 +0000</lastBuildDate>
            <generator>wpForo</generator>
            <ttl>60</ttl>
							                    <item>
                        <title>RE: QNAP - SSH - Manually rebuild &quot;inactive volume&quot; (some useful commands)</title>
                        <link>https://www.tweaking4all.com/forum/qnap-nas/qnap-ssh-manually-rebuild-inactive-volume-some-useful-commands/#post-5765</link>
                        <pubDate>Tue, 28 Jan 2025 13:53:35 +0000</pubDate>
                        <description><![CDATA[Apologies for the very late response ... &#x1f61e; 
Sounds like your QNAP is already actively doing something (rebuild the array maybe?).I would highly recommend contacting QNAP support - a...]]></description>
                        <content:encoded><![CDATA[<p>Apologies for the very late response ... &#x1f61e; </p>
<p>Sounds like your QNAP is already actively doing something (rebuild the array maybe?).<br />I would highly recommend contacting QNAP support - as most, I'm not eager to have someone tinker on my NAS, but in complicated cases I had to resort to them as well (this is where I get some of my tips from as well).</p>
<p>If you'd rather not contact them: I found <a href="https://forum.qnap.com/viewtopic.php?p=871397&amp;sid=cfc659c9cb13a30691729e1cc091cc78" target="_blank" rel="noopener">this forum post</a> in the QNAP forum that may be helpful?</p>]]></content:encoded>
						                            <category domain="https://www.tweaking4all.com/forum/qnap-nas/">QNAP NAS</category>                        <dc:creator>Hans</dc:creator>
                        <guid isPermaLink="true">https://www.tweaking4all.com/forum/qnap-nas/qnap-ssh-manually-rebuild-inactive-volume-some-useful-commands/#post-5765</guid>
                    </item>
				                    <item>
                        <title>RE: QNAP - SSH - Manually rebuild &quot;inactive volume&quot; (some useful commands)</title>
                        <link>https://www.tweaking4all.com/forum/qnap-nas/qnap-ssh-manually-rebuild-inactive-volume-some-useful-commands/#post-5758</link>
                        <pubDate>Sat, 11 Jan 2025 09:46:48 +0000</pubDate>
                        <description><![CDATA[Hi! Trying to follow your post as my Volume is in NOT ACTIVE state, I am stuck at the last comand mdam -AfR ....
is telling me that
mdadm: -E would set mdadm mode to &quot;misc&quot; but it is alrea...]]></description>
                        <content:encoded><![CDATA[<p>Hi! Trying to follow your post as my Volume is in NOT ACTIVE state, I am stuck at the last comand mdam -AfR ....</p>
<p>is telling me that</p>
<p>mdadm: -E would set mdadm mode to "misc" but it is already in mode "assemble"</p>
<p>What should I do in this case?</p>
<p> </p>
<p>Thanks!</p>]]></content:encoded>
						                            <category domain="https://www.tweaking4all.com/forum/qnap-nas/">QNAP NAS</category>                        <dc:creator>Anonymous</dc:creator>
                        <guid isPermaLink="true">https://www.tweaking4all.com/forum/qnap-nas/qnap-ssh-manually-rebuild-inactive-volume-some-useful-commands/#post-5758</guid>
                    </item>
				                    <item>
                        <title>RE: QNAP - SSH - Manually rebuild &quot;inactive volume&quot; (some useful commands)</title>
                        <link>https://www.tweaking4all.com/forum/qnap-nas/qnap-ssh-manually-rebuild-inactive-volume-some-useful-commands/#post-5583</link>
                        <pubDate>Sun, 25 Aug 2024 09:36:45 +0000</pubDate>
                        <description><![CDATA[Sorry for the delayed response - did you hear anything from support yet?I&#039;m very hesitant to make any suggestions, since I&#039;m really not an expert and I&#039;d be nervous about data loss. Even on ...]]></description>
                        <content:encoded><![CDATA[<p>Sorry for the delayed response - did you hear anything from support yet?<br />I'm very hesitant to make any suggestions, since I'm really not an expert and I'd be nervous about data loss. Even on my own system I'd be nervous.</p>
<p>You could try and see what the output of <strong>md_checker</strong> says (in SSH), but like I said: I'd be nervous to tinker with that. Better be patient (I wouldn't be patient either &#x1f609; ) and have support look at it before tinker with it yourself.</p>]]></content:encoded>
						                            <category domain="https://www.tweaking4all.com/forum/qnap-nas/">QNAP NAS</category>                        <dc:creator>Hans</dc:creator>
                        <guid isPermaLink="true">https://www.tweaking4all.com/forum/qnap-nas/qnap-ssh-manually-rebuild-inactive-volume-some-useful-commands/#post-5583</guid>
                    </item>
				                    <item>
                        <title>RE: QNAP - SSH - Manually rebuild &quot;inactive volume&quot; (some useful commands)</title>
                        <link>https://www.tweaking4all.com/forum/qnap-nas/qnap-ssh-manually-rebuild-inactive-volume-some-useful-commands/#post-5582</link>
                        <pubDate>Fri, 23 Aug 2024 10:59:50 +0000</pubDate>
                        <description><![CDATA[Yes, I did it.]]></description>
                        <content:encoded><![CDATA[<p>Yes, I did it.</p>]]></content:encoded>
						                            <category domain="https://www.tweaking4all.com/forum/qnap-nas/">QNAP NAS</category>                        <dc:creator>Anonymous</dc:creator>
                        <guid isPermaLink="true">https://www.tweaking4all.com/forum/qnap-nas/qnap-ssh-manually-rebuild-inactive-volume-some-useful-commands/#post-5582</guid>
                    </item>
				                    <item>
                        <title>RE: QNAP - SSH - Manually rebuild &quot;inactive volume&quot; (some useful commands)</title>
                        <link>https://www.tweaking4all.com/forum/qnap-nas/qnap-ssh-manually-rebuild-inactive-volume-some-useful-commands/#post-5581</link>
                        <pubDate>Fri, 23 Aug 2024 10:51:23 +0000</pubDate>
                        <description><![CDATA[Yeah, there can be a delay ... I recall their support sitting in Taiwan, so time difference is definitely not helping.Last time they helped, I had to enable the support app in the QNAP Web i...]]></description>
                        <content:encoded><![CDATA[<p>Yeah, there can be a delay ... I recall their support sitting in Taiwan, so time difference is definitely not helping.<br />Last time they helped, I had to enable the support app in the QNAP Web interface, something you may want to look into.<br />They use this to get remote access to your QNAP (with your permission). Without it they may not even be able to see what may be going on.<br />Did you go through those steps?<br /><br /></p>]]></content:encoded>
						                            <category domain="https://www.tweaking4all.com/forum/qnap-nas/">QNAP NAS</category>                        <dc:creator>Hans</dc:creator>
                        <guid isPermaLink="true">https://www.tweaking4all.com/forum/qnap-nas/qnap-ssh-manually-rebuild-inactive-volume-some-useful-commands/#post-5581</guid>
                    </item>
				                    <item>
                        <title>RE: QNAP - SSH - Manually rebuild &quot;inactive volume&quot; (some useful commands)</title>
                        <link>https://www.tweaking4all.com/forum/qnap-nas/qnap-ssh-manually-rebuild-inactive-volume-some-useful-commands/#post-5580</link>
                        <pubDate>Fri, 23 Aug 2024 10:43:38 +0000</pubDate>
                        <description><![CDATA[I wrote to technical support. I have been waiting for an answer for two days. Still no answer. &#x1f62a;]]></description>
                        <content:encoded><![CDATA[<p>I wrote to technical support. I have been waiting for an answer for two days. Still no answer. &#x1f62a; </p>]]></content:encoded>
						                            <category domain="https://www.tweaking4all.com/forum/qnap-nas/">QNAP NAS</category>                        <dc:creator>Anonymous</dc:creator>
                        <guid isPermaLink="true">https://www.tweaking4all.com/forum/qnap-nas/qnap-ssh-manually-rebuild-inactive-volume-some-useful-commands/#post-5580</guid>
                    </item>
				                    <item>
                        <title>RE: QNAP - SSH - Manually rebuild &quot;inactive volume&quot; (some useful commands)</title>
                        <link>https://www.tweaking4all.com/forum/qnap-nas/qnap-ssh-manually-rebuild-inactive-volume-some-useful-commands/#post-5579</link>
                        <pubDate>Fri, 23 Aug 2024 10:26:51 +0000</pubDate>
                        <description><![CDATA[Hello there!
Well I&#039;m not a QNAP specialist, just sharing things I&#039;ve learned &#x1f609; 
I would highly recommend contacting QNAP Support (link).I&#039;m not a fan of having someone tinker on m...]]></description>
                        <content:encoded><![CDATA[<p>Hello there!</p>
<p>Well I'm not a QNAP specialist, just sharing things I've learned &#x1f609; </p>
<p>I would highly recommend contacting QNAP Support (<a href="https://service.qnap.com/" target="_blank" rel="noopener">link</a>).<br />I'm not a fan of having someone tinker on my QNAP either, but I have had great support from them twice now, so I can really recommend them for tricky situations like this. I've had two situations where I almost lost all my data, and they did fix the issue.</p>
<p>It's free, and they will help you remotely. <br />You only have to follow the link, setup a free account (no credit card needed), and post a support ticket (you will need the serial number of your QNAP, which you can find on the back of you QNAP or easier: in the web interace QNAP -&gt; Control Panel.</p>
<p>I'm sorry I do not have a cookie cut fix &#x1f61e; </p>]]></content:encoded>
						                            <category domain="https://www.tweaking4all.com/forum/qnap-nas/">QNAP NAS</category>                        <dc:creator>Hans</dc:creator>
                        <guid isPermaLink="true">https://www.tweaking4all.com/forum/qnap-nas/qnap-ssh-manually-rebuild-inactive-volume-some-useful-commands/#post-5579</guid>
                    </item>
				                    <item>
                        <title>RE: QNAP - SSH - Manually rebuild &quot;inactive volume&quot; (some useful commands)</title>
                        <link>https://www.tweaking4all.com/forum/qnap-nas/qnap-ssh-manually-rebuild-inactive-volume-some-useful-commands/#post-5578</link>
                        <pubDate>Fri, 23 Aug 2024 10:14:29 +0000</pubDate>
                        <description><![CDATA[Hello friend.You are a cool specialist of QNAP really need your help. My volumes went into the disabled state, I don&#039;t know what to do with it. Help please]]></description>
                        <content:encoded><![CDATA[<p>Hello friend.<br />You are a cool specialist of QNAP really need your help. My volumes went into the disabled state, I don't know what to do with it. Help please</p>
<p><a title="SSH" href="https://ltdfoto.ru/image/huDWgu" target="_blank" rel="noopener">https://ltdfoto.ru/image/huDWgu</a></p>
<p><a title="volume" href="https://ltdfoto.ru/image/huLRtu" target="_blank" rel="noopener">https://ltdfoto.ru/image/huLRtu</a></p>
<p><a title="HDD" href="https://ltdfoto.ru/image/huLTHH" target="_blank" rel="noopener">https://ltdfoto.ru/image/huLTHH</a></p>]]></content:encoded>
						                            <category domain="https://www.tweaking4all.com/forum/qnap-nas/">QNAP NAS</category>                        <dc:creator>Anonymous</dc:creator>
                        <guid isPermaLink="true">https://www.tweaking4all.com/forum/qnap-nas/qnap-ssh-manually-rebuild-inactive-volume-some-useful-commands/#post-5578</guid>
                    </item>
				                    <item>
                        <title>QNAP - SSH - Manually rebuild &quot;inactive volume&quot; (some useful commands)</title>
                        <link>https://www.tweaking4all.com/forum/qnap-nas/qnap-ssh-manually-rebuild-inactive-volume-some-useful-commands/#post-5348</link>
                        <pubDate>Fri, 16 Feb 2024 14:07:59 +0000</pubDate>
                        <description><![CDATA[Here some info I got my hands on, when trying to recover my RAID Volume that had become inactive after encountering a backplate issue which would at random eject my disk - naturally, this ba...]]></description>
                        <content:encoded><![CDATA[<p>Here some info I got my hands on, when trying to recover my RAID Volume that had become inactive after encountering a backplate issue which would at random eject my disk - naturally, this backplane issue needs to be resolved since this error (in my situation) will happen again ofcourse. </p>
<p>Anyhoo - I've seen some interesting commands that may be helpful for others.</p>
<hr />
<p style="text-align: center"><span style="color: #ff0000;font-size: 14pt"><strong>CAUTION:</strong></span><br /><span style="color: #ff0000;font-size: 12pt">Only use these commands if you know what you're doing.</span><br /><span style="color: #ff0000;font-size: 12pt">In general I'd recommend contacting QNAP support and have them look at it.<br />QNAP has very good support, even for old QNAP (EOL) models!</span></p>
<hr />
<p>First of all, all these commands are executed through an SSH (Shell) connection. <a href="https://www.tweaking4all.com/network-internet/ssh-clients/" target="_blank" rel="noopener">This old QNAP article</a> or <a href="https://www.qnap.com/en/how-to/knowledge-base/article/how-to-access-qnap-nas-by-ssh" target="_blank" rel="noopener">this official QNAP article</a> may be helpful, but then again: if you do not know what an SSH connection is, you'd probably be better off by contacting QNAP support.</p>
<p> </p>
<p><strong>Check RAID Status</strong></p>
<p>The easiest way to check the RAID status is done with md_checher, which should be on your QNAP by default (my old QTS4 QNAP and newer QTS5 QNAP had it both installed):</p>
<pre contenteditable="false">md_checker</pre>
<p>In my case this generated a list like this, where the "AAAA.AA." probably indicates trouble as it seems to be missing two spots. </p>
<pre contenteditable="false">Welcome to MD superblock checker (v1.4) - have a nice day~

Scanning system...

HAL firmware detected!
Scanning Enclosure 0...

RAID metadata found!
UUID:		aac26467:7ef59f4f:51673f80:8c31584b
Level:		raid6
Devices:	8
Name:		md1
Chunk Size:	64K
md Version:	1.0
Creation Time:	Sep 7 19:53:43 2020
Status:		OFFLINE
===============================================================================
 Disk | Device | # | Status |   Last Update Time   | Events | Array State
===============================================================================
   1  /dev/sda3  0   Active   Feb  8 14:41:00 2024    58609   AAAA.AA.                 
   2  /dev/sdb3  1   Active   Feb  8 14:41:00 2024    58609   AAAA.AA.                 
   3  /dev/sdc3  2   Active   Feb  8 14:41:00 2024    58609   AAAA.AA.                 
   4  /dev/sdd3  3   Active   Feb  8 14:41:00 2024    58609   AAAA.AA.                 
   5  /dev/sde3  4   Active   Feb  8 14:36:42 2024    58422   AAAAAAAA                 
   6  /dev/sdf3  5   Active   Feb  8 14:36:42 2024    58422   AAAAAAAA                 
   7  /dev/sdg3  6   Active   Feb  8 14:36:42 2024    58422   AAAAAAAA                 
   8  /dev/sdh3  7   Active   Feb  8 14:36:42 2024    58422   AAAAAAAA                 
===============================================================================
</pre>
<p> </p>
<p><strong>Check if Disks are Detected properly</strong></p>
<p>As show in my <a href="https://www.tweaking4all.com/forum/qnap-nas/qnap-ssh-command-to-list-all-internal-disks-qcli_storage/" target="_blank" rel="noopener">previous post</a>, we can use <strong>qcli_storage</strong> storage for that:</p>
<pre contenteditable="false">qcli_storage -d</pre>
<p>On my NAS all disks were detected properly:</p>
<pre contenteditable="false">Enclosure  Port  Sys_Name     Type      Size      Alias          Signature   Partitions  Model  
NAS_HOST   1     /dev/sda     HDD:data  3.64 TB   --             QNAP FLEX   5           WDC WD40EFRX-68N32N0
NAS_HOST   2     /dev/sdb     HDD:data  3.64 TB   --             QNAP FLEX   5           WDC WD40EFRX-68N32N0
NAS_HOST   3     /dev/sdc     HDD:data  3.64 TB   --             QNAP FLEX   5           WDC WD40EFRX-68N32N0
NAS_HOST   4     /dev/sdd     HDD:data  3.64 TB   --             QNAP FLEX   5           WDC WD40EFZX-68AWUN0
NAS_HOST   5     /dev/sde     HDD:free  3.64 TB   --             QNAP FLEX   5           WDC WD40EFRX-68N32N0
NAS_HOST   6     /dev/sdf     HDD:free  3.64 TB   --             QNAP FLEX   5           WDC WD40EFZX-68AWUN0
NAS_HOST   7     /dev/sdg     HDD:free  3.64 TB   --             QNAP FLEX   5           WDC WD40EFRX-68N32N0
NAS_HOST   8     /dev/sdh     HDD:free  3.64 TB   --             QNAP FLEX   5           WDC WD40EFRX-68N32N0</pre>
<p> </p>
<p><strong>Check if all disks have RAID (md) information</strong></p>
<p>Next we need to check all disks to see if they have md superblock information:</p>
<pre contenteditable="false">mdadm -E /dev/sda3
mdadm -E /dev/sdb3
mdadm -E /dev/sdc3
mdadm -E /dev/sdd3
mdadm -E /dev/sde3
mdadm -E /dev/sdf3
mdadm -E /dev/sdg3
mdadm -E /dev/sdh3</pre>
<p>Example output of one of my disks:</p>
<pre contenteditable="false">/dev/sda3:
          Magic : a92b4efc
        Version : 1.0
    Feature Map : 0x0
     Array UUID : aac26467:7ef59f4f:51673f80:8c31584b
           Name : 1
  Creation Time : Mon Sep  7 19:53:43 2020
     Raid Level : raid6
   Raid Devices : 8

 Avail Dev Size : 7794127240 (3716.53 GiB 3990.59 GB)
     Array Size : 23382381696 (22299.18 GiB 23943.56 GB)
  Used Dev Size : 7794127232 (3716.53 GiB 3990.59 GB)
   Super Offset : 7794127504 sectors
   Unused Space : before=0 sectors, after=264 sectors
          State : clean
    Device UUID : b8d7db50:63e4ca78:53c5877e:2e946fd0

    Update Time : Thu Feb  8 14:41:00 2024
  Bad Block Log : 512 entries available at offset -8 sectors
       Checksum : 7b01bedb - correct
         Events : 58609

         Layout : left-symmetric
     Chunk Size : 64K

   Device Role : Active device 0
   Array State : AAAA.AA. ('A' == active, '.' == missing, 'R' == replacing)</pre>
<p> </p>
<p><strong>Manually reassemble the RAID</strong></p>
<p><span style="color: #ff0000"><strong>CAUTION</strong>: This step may damage your RAID volume! If unsure: contact QNAP support!</span></p>
<p>Now, if all disks have md information (<strong>Device Role</strong> shows <strong>Active device #</strong>), you can include all these disks (8 in my case) to manually reassemble the RAID (md1) like so:</p>
<pre contenteditable="false">mdadm -AfR /dev/md1 mdadm -E /dev/sda3 mdadm -E /dev/sdb3 mdadm -E /dev/sdc3 mdadm -E /dev/sdd3 mdadm -E /dev/sde3 mdadm -E /dev/sdf3 mdadm -E /dev/sdg3 mdadm -E /dev/sdh3</pre>
<p>Now if a disk is missing (max 1 for RAID 5, and max 2 for RAID 6) then you can skip those in this command.<br />If you have too many disks missing, or too many disks with missing md information, then you will not be able to use the "<strong>mdadm -AfR</strong>" command to reassemble the RAID.<br /><br /></p>
<p><strong>Verify and bringing the volume back online</strong></p>
<p>When all that was completed successfully, verify if RAID is online, again with md_checker:</p>
<pre contenteditable="false">md_checker</pre>
<p><br />If md_checker is showing that the RAID is ONLINE again, then you can the following to recover the storage config:</p>
<pre contenteditable="false">/ etc/init.d/init_lvm,sh</pre>
<p>(remove the space between the slah forward and "etc" - mod_security of the webserver doesn't seem to like it)</p>
<p>You can after that verify if the RAID and volume are good.<br />If you are not familiar with these commands, then please read up on them before using them.<br /><em>Some references:</em> <a href="https://man7.org/linux/man-pages/man8/pvs.8.html" target="_blank" rel="noopener">pvs</a>, <a href="https://man7.org/linux/man-pages/man8/vgs.8.html" target="_blank" rel="noopener">vgs</a>, <a href="https://man7.org/linux/man-pages/man8/lvs.8.html" target="_blank" rel="noopener">lvs</a>, <a href="https://man7.org/linux/man-pages/man1/df.1p.html" target="_blank" rel="noopener">df</a>, <a href="https://man7.org/linux/man-pages/man8/mount.8.html" target="_blank" rel="noopener">mount</a>.</p>
<pre contenteditable="false">md_checker
pvs
vgs
lvs -a
ls -l /dev/mapper/
df
mount</pre>
<p><br />After this, the volume is usually name "/dev/mapper/cachedev<span style="color: #ff0000">X</span>" which mounts to "/share/CACHEDEV<span style="color: #ff0000">X</span>_DATA".<br />For example the volume such as /dev/mapper/cachedev1 is mounted to path /share/CACHEDEV1_DATA.</p>
<p>You can then verify the content "File Station" or in the Shell with for example:</p>
<pre contenteditable="false">ls -l /share/CACHEDEV1_DATA/</pre>
Hope this is useful to fellow QNAP users.]]></content:encoded>
						                            <category domain="https://www.tweaking4all.com/forum/qnap-nas/">QNAP NAS</category>                        <dc:creator>Hans</dc:creator>
                        <guid isPermaLink="true">https://www.tweaking4all.com/forum/qnap-nas/qnap-ssh-manually-rebuild-inactive-volume-some-useful-commands/#post-5348</guid>
                    </item>
							        </channel>
        </rss>
		