close

Privacy guaranteed - Your email is not shared with anyone.

A Question for the Guru's

Discussion in 'Tech Talk' started by Bushflyr, Apr 10, 2012.


  1. Bushflyr

    Bushflyr
    Expand Collapse
    ʇno uıƃuɐɥ ʇsnɾ
    Millennium Member

    Joined:
    Mar 17, 1999
    3,524
    0
    Location:
    Western WA
    Hi all. I'm currently building a small home server, Ubuntu server 11.10, for music, movies, storage, and security cams. It's an i5 processor on a Jetway JNF9A mobo with 1 WD 500GB OS drive and 4 Seagate 2TB drives set up 3 RAID 5 1 spare.

    My other machines are all Mac's so I mostly followed the instructions in THIS THREAD. The first two times I tried to back up my iMac to the server with TM it completely crashed it so I reinstalled from scratch. The second time it crashed the RAID, but (I think) it was only SDB that it had listed as failed. I was able to unmount and recover the RAID with mdadm. The third time I left it to back up over night and woke to find two disks (I think sdb and sdc, but not sure) listed as failed. After much tooth gnashing I found the "failed" disks listed as part of md127 and was able to reconstruct the RAID from scratch.

    This last time I went to bed and disabled sleep on my iMac. TM successfully backed up over night. Now I just came home from the beach to find the raid rebuilding from a failed sdc and a fresh, successful, TM backup as of 30 minutes ago.

    So, I'm trying to figure out why it's "failing" the disks erroneously and how to fix it. Any help is greatly appreciated.

    Code:
    [~]: sudo cat /proc/mdstat
    Personalities : [linear] [multipath] [raid0] [raid1] [raid6] [raid5] [raid4] [raid10]
    md0 : active raid5 sdb1[0] sdd1[4] sde1[3] sdc1[1](F)
          3907023872 blocks super 1.2 level 5, 512k chunk, algorithm 2 [3/2] [U_U]
          [==========>..........]  recovery = 53.5% (1045589816/1953511936) finish=135.0min speed=112012K/sec
          
    unused devices: <none>
    [~]: sudo smartctl -t short /dev/sdc
    smartctl 5.41 2011-06-09 r3365 [x86_64-linux-3.0.0-17-server] (local build)
    Copyright (C) 2002-11 by Bruce Allen, http://smartmontools.sourceforge.net
    
    Short INQUIRY response, skip product id
    A mandatory SMART command failed: exiting. To continue, add one or more '-T permissive' options.
    
    So after it finally finished rebuilding I did an examine and detail scan and got:

    Code:
    [~]: sudo mdadm --examine /dev/sdc
    mdadm: No md superblock detected on /dev/sdc.
    [~]: sudo mdadm --detail --scan
    ARRAY /dev/md0 metadata=1.2 name=mars:0 UUID=9ec6ec09:8834b3f7:adc08875:2ae05753
    [~]: sudo mdadm --detail /dev/md0
    /dev/md0:
            Version : 1.2
      Creation Time : Fri Apr  6 10:14:03 2012
         Raid Level : raid5
         Array Size : 3907023872 (3726.03 GiB 4000.79 GB)
      Used Dev Size : 1953511936 (1863.01 GiB 2000.40 GB)
       Raid Devices : 3
      Total Devices : 4
        Persistence : Superblock is persistent
    
        Update Time : Mon Apr  9 14:52:38 2012
              State : clean
     Active Devices : 3
    Working Devices : 3
     Failed Devices : 1
      Spare Devices : 0
    
             Layout : left-symmetric
         Chunk Size : 512K
    
               Name : mars:0  (local to host mars)
               UUID : 9ec6ec09:8834b3f7:adc08875:2ae05753
             Events : 384
    
        Number   Major   Minor   RaidDevice State
           0       8       17        0      active sync   /dev/sdb1
           3       8       65        1      active sync   /dev/sde1
           4       8       49        2      active sync   /dev/sdd1
    
           1       8       33        -      faulty spare   /dev/sdc1
    
    And Smartctl returned:
    Code:
    [~]: sudo smartctl -d ata -a /dev/sdc -T permissive
    smartctl 5.41 2011-06-09 r3365 [x86_64-linux-3.0.0-17-server] (local build)
    Copyright (C) 2002-11 by Bruce Allen, http://smartmontools.sourceforge.net
    
    Smartctl: Device Read Identity Failed: Input/output error
    
    === START OF INFORMATION SECTION ===
    Device Model:     [No Information Found]
    Serial Number:    [No Information Found]
    Firmware Version: [No Information Found]
    Device is:        Not in smartctl database [for details use: -P showall]
    ATA Version is:   [No Information Found]
    ATA Standard is:  [No Information Found]
    Local Time is:    Mon Apr  9 14:59:51 2012 HST
    SMART support is: Ambiguous - ATA IDENTIFY DEVICE words 82-83 don't show if SMART supported.
    SMART support is: Ambiguous - ATA IDENTIFY DEVICE words 85-87 don't show if SMART is enabled.
    A mandatory SMART command failed: exiting. To continue, add one or more '-T permissive' options.
    
    Then after rebooting I get:
    Code:
    === START OF INFORMATION SECTION ===
    Model Family:     Seagate Barracuda Green (Adv. Format)
    Device Model:     ST2000DL003-9VT166
    Serial Number:    5YD796YM
    LU WWN Device Id: 5 000c50 046e10bb7
    Firmware Version: CC3C
    User Capacity:    2,000,398,934,016 bytes [2.00 TB]
    Sector Sizes:     512 bytes logical, 4096 bytes physical
    Device is:        In smartctl database [for details use: -P show]
    ATA Version is:   8
    ATA Standard is:  ATA-8-ACS revision 4
    Local Time is:    Mon Apr  9 15:08:03 2012 HST
    SMART support is: Available - device has SMART capability.
    SMART support is: Enabled
    
    === START OF READ SMART DATA SECTION ===
    SMART overall-health self-assessment test result: PASSED
    
    General SMART Values:
    Offline data collection status:  (0x82)    Offline data collection activity
                        was completed without error.
                        Auto Offline Data Collection: Enabled.
    Self-test execution status:      (   0)    The previous self-test routine completed
                        without error or no self-test has ever
                        been run.
    Total time to complete Offline
    data collection:         (  612) seconds.
    Offline data collection
    capabilities:              (0x7b) SMART execute Offline immediate.
                        Auto Offline data collection on/off support.
                        Suspend Offline collection upon new
                        command.
                        Offline surface scan supported.
                        Self-test supported.
                        Conveyance Self-test supported.
                        Selective Self-test supported.
    SMART capabilities:            (0x0003)    Saves SMART data before entering
                        power-saving mode.
                        Supports SMART auto save timer.
    Error logging capability:        (0x01)    Error logging supported.
                        General Purpose Logging supported.
    Short self-test routine
    recommended polling time:      (   1) minutes.
    Extended self-test routine
    recommended polling time:      ( 255) minutes.
    Conveyance self-test routine
    recommended polling time:      (   2) minutes.
    SCT capabilities:            (0x30b7)    SCT Status supported.
                        SCT Feature Control supported.
                        SCT Data Table supported.
    
    SMART Attributes Data Structure revision number: 10
    Vendor Specific SMART Attributes with Thresholds:
    ID# ATTRIBUTE_NAME          FLAG     VALUE WORST THRESH TYPE      UPDATED  WHEN_FAILED RAW_VALUE
      1 Raw_Read_Error_Rate     0x000f   102   099   006    Pre-fail  Always       -       200408
      3 Spin_Up_Time            0x0003   092   092   000    Pre-fail  Always       -       0
      4 Start_Stop_Count        0x0032   100   100   020    Old_age   Always       -       127
      5 Reallocated_Sector_Ct   0x0033   100   100   036    Pre-fail  Always       -       0
      7 Seek_Error_Rate         0x000f   064   060   030    Pre-fail  Always       -       2784264
      9 Power_On_Hours          0x0032   100   100   000    Old_age   Always       -       238
     10 Spin_Retry_Count        0x0013   100   100   097    Pre-fail  Always       -       0
     12 Power_Cycle_Count       0x0032   100   100   020    Old_age   Always       -       135
    183 Runtime_Bad_Block       0x0032   100   100   000    Old_age   Always       -       0
    184 End-to-End_Error        0x0032   100   100   099    Old_age   Always       -       0
    187 Reported_Uncorrect      0x0032   100   100   000    Old_age   Always       -       0
    188 Command_Timeout         0x0032   100   098   000    Old_age   Always       -       11
    189 High_Fly_Writes         0x003a   100   100   000    Old_age   Always       -       0
    190 Airflow_Temperature_Cel 0x0022   063   053   045    Old_age   Always       -       37 (Min/Max 37/37)
    191 G-Sense_Error_Rate      0x0032   100   100   000    Old_age   Always       -       0
    192 Power-Off_Retract_Count 0x0032   100   100   000    Old_age   Always       -       57
    193 Load_Cycle_Count        0x0032   100   100   000    Old_age   Always       -       135
    194 Temperature_Celsius     0x0022   037   047   000    Old_age   Always       -       37 (0 20 0 0)
    195 Hardware_ECC_Recovered  0x001a   024   012   000    Old_age   Always       -       200408
    197 Current_Pending_Sector  0x0012   100   100   000    Old_age   Always       -       0
    198 Offline_Uncorrectable   0x0010   100   100   000    Old_age   Offline      -       0
    199 UDMA_CRC_Error_Count    0x003e   200   200   000    Old_age   Always       -       0
    240 Head_Flying_Hours       0x0000   100   253   000    Old_age   Offline      -       277643865882863
    241 Total_LBAs_Written      0x0000   100   253   000    Old_age   Offline      -       200775748
    242 Total_LBAs_Read         0x0000   100   253   000    Old_age   Offline      -       2481998573
    
    SMART Error Log Version: 1
    No Errors Logged
    
    SMART Self-test log structure revision number 1
    Num  Test_Description    Status                  Remaining  LifeTime(hours)  LBA_of_first_error
    # 1  Short offline       Completed without error       00%        42         -
    
    SMART Selective self-test log data structure revision number 1
     SPAN  MIN_LBA  MAX_LBA  CURRENT_TEST_STATUS
        1        0        0  Not_testing
        2        0        0  Not_testing
        3        0        0  Not_testing
        4        0        0  Not_testing
        5        0        0  Not_testing
    Selective self-test flags (0x0):
      After scanning selected spans, do NOT read-scan remainder of disk.
    If Selective self-test is pending on power-up, resume after 0 minute delay.
    
    Possible cable issue?
     

    Wanna kill these ads? We can help!
  2. gemeinschaft

    gemeinschaft
    Expand Collapse
    AKA Fluffy316

    Joined:
    Feb 7, 2004
    2,181
    0
    Location:
    Houston, TX
    I like what you are doing and I am sure IGF will have his opinion, but for what you are trying to do, it looks as if OpenMediaVault will do exactly what you want it to do.

    If you decide to try this route, I would unhook all drives and use a 8-16gb USB Flash drive as your OS drive.

    Then, configure the RAID across the disks that you have.

    My experience with Linux has been that it can get picky when it comes to hardware RAID configurations, but software RAID seems to be the way to go.

    I am sure someone will chime in with a different opinion, but you know what they say about opinions.

    I know this would mean that everything you did up this point would be for nothing, but it's an option. LOL

    The best part is, it is a fast install that requires nothing except a Password and a Static IP on your LAN. After that, it is a simple GUI config.

    Here is a link on my site discussing OMV if you want to check it out : https://sites.google.com/site/cookingcomputersandmore/home/computers-electronics-and-gadgets/set-up-your-own-network-attached-storage-device

    The thing about TimeMachine that rusts my buttons is that it will continue to run backups until the storage media is full, then it will start removing the oldest files in order to make space.

    TimeMachine was like a virus consuming my NAS until I decided to give it a static Storage container size. This is probably something you want to look into before it becomes an issue for you as well, if this is not something that you have already planned for.
     

  3. IndyGunFreak

    IndyGunFreak
    Expand Collapse
    KO Windows

    Joined:
    Jan 26, 2001
    25,699
    982
    Location:
    Indiana
    Well, I'll have to yield the floor on this one, because I have no idea what could be wrong.

    OMV.. could be a solution. It does have an easy to use webUI (if that sort of thing interests you), and it might offer some clues if your RAID continues to fail. I've been considering putting OMV back on my home server. Not because Ubuntu server isn't working (or even that I have any desire to use a webUI)... it's just that I like the OMV project, and try to support it when I can (helping new users, etc.).... I figure I'd be a hypocrite to suggest it to people, and not have it myself.. :)
     
    #3 IndyGunFreak, Apr 10, 2012
    Last edited: Apr 10, 2012
  4. Bushflyr

    Bushflyr
    Expand Collapse
    ʇno uıƃuɐɥ ʇsnɾ
    Millennium Member

    Joined:
    Mar 17, 1999
    3,524
    0
    Location:
    Western WA
    Thanks for the input. At least I know I'm not going (too) insane. :) I should have put in the OP, this is a software RAID 5 set up with mdadm.

    Whoops, I forgot to make the original How-To link hot, it's HERE.

    I thought about OMV or FreeNAS, but they didn't seem like they were the best solution (or if they'd even work) for running Zoneminder or Motion for the cameras.

    That was my original plan. I tried it a few times but it wasn't working well so I threw an old drive into one of the spare bays to get things working. I may go back and try it again if I run out of space as the mobo only has 6 SATA ports.

    Yeah, that's why I used mdadm, I've had proprietary RAID hardware fail on me before resulting in total data loss. :crying:

    And not a bad one. At this point I've done it enough that, aside from building the RAID, it only takes me a couple hours.

    This box is headless and going to be installed in my gun safe, so I figured a GUI was more hassle than it was worth. Everything is done over ssh.

    It wasn't, except along the lines of having a lot of space. How do you assign a static container size? Just put it on its own partition?

    Thanks for the help. :supergrin: I am learning a ton with this project, and I WILL get running like I want. Even if it kills me. :faint:
     
  5. gemeinschaft

    gemeinschaft
    Expand Collapse
    AKA Fluffy316

    Joined:
    Feb 7, 2004
    2,181
    0
    Location:
    Houston, TX

    First of all, I think I need to clarify something about OMV, once installed and configured with a PW and an IP address, it is configured through the web browser of any computer on the LAN by navigating to it's ip address in your web browser. You simply plug it into power and plug it into the network, that is all.

    I would recommend leaving the network settings as DHCP and assigning the Static IP from your Router.

    Motion looks like an application for USB cameras only, I could be wrong.

    Being that OMV is Debian based, I would think that you could install ZoneMinder on the OMV box.

    The only way I was able to contain TimeMachine from taking over the NAS was put it on it's own partition as you suggested (Thanks alot Apple!):rofl::rofl:

    If you decide to go this route, I would get everything configured the way you want and then shutdown the server, take the OS harddrive and using clonezilla, make a copy. This way, you have a spare in case your OS Drive ever fails.

    The part about placing this server into your GunSafe has me a little concerned about heat issues, but I am hoping that you have already sorted this out. Depending on the size of the safe, it could be an issue to sort out.

    I use FTP to send stills from my camera to on offsite storage account at Sensr.net Offsite Storage for IP cameras

    If I had enough storage and a safe large enough to house my server comfortably, I'd likely look at the options that you are planning.

    I wouldn't bother with FreeNAS. The newer versions have gone to the dogs, where OMV seems to take the cake.
     
  6. Bushflyr

    Bushflyr
    Expand Collapse
    ʇno uıƃuɐɥ ʇsnɾ
    Millennium Member

    Joined:
    Mar 17, 1999
    3,524
    0
    Location:
    Western WA
    Cool, I just read your OMV page. Nice writeup. I'm going to snag one of my old boxes from the closet and stuff it full of all the random drives I have lying around and see what happens. I'm giggling already. Maybe make a case for it out of broken surfboards. OK, maybe not, but I think it'll be super fun to kludge the whole thing together.

    Good call on clonezilla. I have the other WD 500 in the last bay, but it's not plugged in yet. I plan to mirror the OS drive to it eventually. Depends on whether or not I need the SATA port for another RAID drive first.

    Putting it in the safe won't be a problem. 2500lbs of steel and guns makes a hell of a heat sink. And this thing runs super cool anyway. The Lian Li PC-Q08 is a fantastic case if you can live with a mini ITX mobo.

    Build specs for anyone that's interested:

    Lian Li PC-Q08A
    Jetway JNF9A
    PSU Coolermaster 460w
    Intel core i5 2400 3.1G
    8GB Corsair 1333
    4 2tb Seagate drives (RAID)
    2 500gb WD drives (OS) only 1 currently in use.
     
  7. gemeinschaft

    gemeinschaft
    Expand Collapse
    AKA Fluffy316

    Joined:
    Feb 7, 2004
    2,181
    0
    Location:
    Houston, TX
    Once you have OMV installed, THEN plug in your storage drives.

    Then, you can setup your RAID, then mount the Filesystem, then create your Shares, give permissions.

    The OMV plugins give you some great plugins like the ability to configure MiniDLNA for Plug and Play access to files from other devices on the network.


    ETA: that given your posted hardware configuration, I think you will have a killer box once it is up and running.

    IGF is the resident expert on OMV, he is the one who got me using it and I love OMV. I just wish I had the cash to build a larger system for my local network, I have plenty of data and never enough storage. Ideally, I would like to RIP my entire DVD library to file and be able to select anything that I want whenever I want. Then again, I guess that's what Netflix is for. LOL
     
    #7 gemeinschaft, Apr 10, 2012
    Last edited: Apr 10, 2012
  8. IndyGunFreak

    IndyGunFreak
    Expand Collapse
    KO Windows

    Joined:
    Jan 26, 2001
    25,699
    982
    Location:
    Indiana
    The Plugin setup for OMV is extremely nice. There's a few plugins that are supported by OMV, then if you add the community plugin repository, it adds a bunch more that are available.

    My home server is pretty simple (samba, ftp, minidlna, daapd, and transmission), software raid 1 on 2, 1.5tb drives, and my "OS" drive, is an old 2.5in 80gig laptop drive.

    It really works well for me, and I like it.

    The only thing about installing OMV to a USB drive. OMV does a fair amount of disk writing, so you may find your USB drives dying frequently.

    I can't offer any suggestion on Apple TM, as I don't use it. From the sounds of it though, gemeinschaft's solution is the way to go though.
     
    #8 IndyGunFreak, Apr 10, 2012
    Last edited: Apr 10, 2012
  9. Bushflyr

    Bushflyr
    Expand Collapse
    ʇno uıƃuɐɥ ʇsnɾ
    Millennium Member

    Joined:
    Mar 17, 1999
    3,524
    0
    Location:
    Western WA
    Have you ever used subsonic? How does it compare to miniDLNA? Or MediaTomb?

    Running off a USB... Everything I've read suggests setting it up to load off the USB then actually run in a ramdrive. Make the USB live longer.

    The setup is working pretty well so far, aside from these hiccups. Oddly enough it seems to be stabilizing a bit as time goes on. For example when I originally installed Subsonic it would skip a bit during playback. Now it's running GREAT! Even streaming to multiple devices, backing up TM, and dumping multi GB files on it in finder and not a pip.

    Upstream speeds, as reported by Menumeters are around 50-70 MB/s up while streaming down. Pretty happy so far. Ecstatic when it's stable enough to forget about.
     
  10. IndyGunFreak

    IndyGunFreak
    Expand Collapse
    KO Windows

    Joined:
    Jan 26, 2001
    25,699
    982
    Location:
    Indiana
    OK, so you piqued my curiosity with this post. Am I correct in understanding you're using OMV now?

    Anyway, the curiosity part, was this subsonic application. Never heard of it. I just reinstalled OMV and installed subsonic. Interesting app. Not really something I need (mainly because forked-daapd and minidlna work fine for me), but not bad. It installs very easily from the .deb on the site you can download.

    Interesting application, thanks for posting. I'll point some OMV folks at this later in the week, and see what they think.
     
  11. IndyGunFreak

    IndyGunFreak
    Expand Collapse
    KO Windows

    Joined:
    Jan 26, 2001
    25,699
    982
    Location:
    Indiana
    That's an interesting case by the way... I almost bought that one when I built my new NAS last month, it was just more than I wanted to spend on a NAS case. It's not quite the speed/specs of yours, but I'm more than happy with it.

    Case -- Antec Sonata Proto
    Motherboard -- MSI 760GM
    CPU -- 2.8gighz AMD Sempron CPU
    RAM -- Crucial 8gigs of 1333 DDR3
    Power Supply -- 500w Antec True Power

    Only thing I kinda regret, is the case. I wish I had went with something smaller. I just got the call that my youngest sister's PC likely bit the dust(I built it almost 9yrs ago). I make put her new PC in the Sonata, and buy me a new NAS case... still debating that though. I don't really need a case with 8-9 drive bays.

    If for some reason I needed more 3.5in bays (unlikely, as I still have 2 internal, and 2 external available).. I'll get something like this and convert the 2 of the 5.25in bays to 3x3.5

    http://www.newegg.com/Product/Product.aspx?Item=N82E16835110018
     
  12. Bushflyr

    Bushflyr
    Expand Collapse
    ʇno uıƃuɐɥ ʇsnɾ
    Millennium Member

    Joined:
    Mar 17, 1999
    3,524
    0
    Location:
    Western WA
    No, I'm running Ubuntu 11.10 Server. I'm going to dig out an old machine from the closet and fire up OMV on it.

    There was a reason the guy that wrote the How-To I followed (mostly) got rid of daapd.

    He writes:
    I didn't look into anything different. If I want to switch it up later I'll do that. Just want to get everything tweaked and running right before making major changes.

    The size of the case was one of the primary considerations as it was built to live in the safe. This one is nice and short. Very space efficient while still being SUPER easy to work in. Both side plates come off with 6 screws. Super stiff and sturdy, huge front fan for the drives, and it looks sweet. It was a bit more than others, but I think it was entirely worth it. I'll probably use one again for a hackintosh build. It's so pretty it seems a shame to stuff it in a closet.

    [​IMG]

    [​IMG]
     
    #12 Bushflyr, Apr 10, 2012
    Last edited: Apr 10, 2012
  13. Bushflyr

    Bushflyr
    Expand Collapse
    ʇno uıƃuɐɥ ʇsnɾ
    Millennium Member

    Joined:
    Mar 17, 1999
    3,524
    0
    Location:
    Western WA
    #13 Bushflyr, Apr 10, 2012
    Last edited: Apr 10, 2012
  14. IndyGunFreak

    IndyGunFreak
    Expand Collapse
    KO Windows

    Joined:
    Jan 26, 2001
    25,699
    982
    Location:
    Indiana
    Essentially that whole article is complaining about iTunes, rather than forked-daapd. While forked-daapd is very simple, and doesn't have a bunch of features, it works quite well with Rhythmbox. I have no problem rating songs, etc.
     
  15. IndyGunFreak

    IndyGunFreak
    Expand Collapse
    KO Windows

    Joined:
    Jan 26, 2001
    25,699
    982
    Location:
    Indiana
    That was another NAS case I considered, but when I did some Googling, there's a pic of what that is "full" and the drive cage had to be bent in so that the power supply could slide all the way in. Very tight fit.

    Maybe it's best to go huge/server type case for your home NAS...lol. All these "small" cases, always seem to have at least one or two drawbacks.

    http://www.frozencpu.com/products/1...ni_ITX_NAS_Case_-_Black_-_w_300W_SFX_PSU.html --- This one got rave reviews from some folks I know, but I don't like the SFX power supply form factor. Not to mention, $$$

    IGF