extrahd: Add UUID to table.
authorArne Fitzenreiter <arne_f@ipfire.org>
Fri, 10 Dec 2010 12:29:23 +0000 (13:29 +0100)
committerArne Fitzenreiter <arne_f@ipfire.org>
Fri, 10 Dec 2010 12:29:23 +0000 (13:29 +0100)
Fix blkid without cache does not work as nobody.

config/extrahd/extrahd.pl
html/cgi-bin/extrahd.cgi
html/cgi-bin/pakfire.cgi [changed mode: 0755->0644]

index 5f623fd1b697aeafc16053847484b41435786d55..6593ca47dea17030ec73494eca2508aaa525e3d4 100644 (file)
@@ -2,7 +2,7 @@
 ###############################################################################
 #                                                                             #
 # IPFire.org - A linux based firewall                                         #
-# Copyright (C) 2007  Michael Tremer & Christian Schmidt                      #
+# Copyright (C) 2010  IPFire Team  <info@ipfire.org>                          #
 #                                                                             #
 # This program is free software: you can redistribute it and/or modify        #
 # it under the terms of the GNU General Public License as published by        #
@@ -84,8 +84,11 @@ if ( "$ARGV[0]" eq "mount" ) {
                exit(1);
        }
 
+} elsif ( "$ARGV[0]" eq "scanhd") {
+       system("/usr/local/bin/scanhd $ARGV[1]");
+
 } else {
-       print "Usage: $0 (mount|umount) mountpoint\n";
+       print "Usage: $0 (mount|umount|scanhd) mountpoint\n";
 }
 
 ############################################################################################################################
index fd3555468afc20740278528e99b35634fc70121e..b9f42abe9649bf90fb6e733403d885d6f4cf102a 100644 (file)
@@ -2,7 +2,7 @@
 ###############################################################################
 #                                                                             #
 # IPFire.org - A linux based firewall                                         #
-# Copyright (C) 2007  Michael Tremer & Christian Schmidt                      #
+# Copyright (C) 2010  IPFire Team  <info@ipfire.org>                          #
 #                                                                             #
 # This program is free software: you can redistribute it and/or modify        #
 # it under the terms of the GNU General Public License as published by        #
@@ -48,8 +48,8 @@ my $partitionentry = "";
 my $devicefile = "/var/ipfire/extrahd/devices";
 my $scanfile = "/var/ipfire/extrahd/scan";
 my $partitionsfile = "/var/ipfire/extrahd/partitions";
-system("/usr/local/bin/scanhd ide");
-system("/usr/local/bin/scanhd partitions");
+system("/usr/local/bin/extrahdctrl scanhd ide");
+system("/usr/local/bin/extrahdctrl scanhd partitions");
 
 &Header::showhttpheaders();
 
@@ -181,7 +181,7 @@ END
                @scanline = split( /\;/, $scanentry );
                print <<END
                        <tr><td colspan="5">&nbsp;
-                       <tr><td align='center'><b>/dev/$scanline[0]</b>
+                       <tr><td align='left' colspan="2"><b>/dev/$scanline[0]</b>
                                <td align='center' colspan="2">$scanline[1]
 END
 ;
@@ -206,9 +206,11 @@ END
                                $size = int($partitionline[1] / 1024);
                                print <<END
                                <form method='post' action='$ENV{'SCRIPT_NAME'}'>
-                               <tr><td align="center">/dev/$partitionline[0]
+                               <tr><td align="left" colspan=5><b>UUID=$partitionline[2]</b></td></tr>
+                               <tr>
+                               <td align="list">/dev/$partitionline[0]</td>
                                <td align="center">$Lang::tr{'size'} $size MB
-                               <td align='center'><select name="FS">
+                               <td align="center"><select name="FS">
                                                                                <option value="auto">auto</option>
                                                                                <option value="ext3">ext3</option>
                                                                                <option value="reiserfs">reiserfs</option>
old mode 100755 (executable)
new mode 100644 (file)