[LON-CAPA-cvs] cvs: doc /install/linux install.pl /loncapafiles ntpcheck.piml

raeburn raeburn at source.lon-capa.org
Mon Dec 2 23:55:11 EST 2019


raeburn		Tue Dec  3 04:55:11 2019 EDT

  Modified files:              
    /doc/install/linux	install.pl 
    /doc/loncapafiles	ntpcheck.piml 
  Log:
  - Ubuntu 18 LTS use chrony instead of ntp. 
  
  
Index: doc/install/linux/install.pl
diff -u doc/install/linux/install.pl:1.60 doc/install/linux/install.pl:1.61
--- doc/install/linux/install.pl:1.60	Thu Nov  7 15:55:31 2019
+++ doc/install/linux/install.pl	Tue Dec  3 04:55:08 2019
@@ -77,7 +77,7 @@
           &mt('Stopping execution.')."\n";
     exit;
 } else {
-    print LOG '$Id: install.pl,v 1.60 2019/11/07 15:55:31 raeburn Exp $'."\n";
+    print LOG '$Id: install.pl,v 1.61 2019/12/03 04:55:08 raeburn Exp $'."\n";
 }
 
 #
@@ -734,6 +734,9 @@
         if (($distro =~ /^ubuntu/) && ($version <= 8)) {
             $daemon{'cups'} = 'cupsys';
         }
+        if (($distro =~ /^ubuntu/) && ($version >= 18)) {
+            $daemon{'ntp'}    = 'chrony';
+        }
     } elsif ($distro =~ /^fedora(\d+)/) {
         my $version = $1;
         if ($version >= 15) {
Index: doc/loncapafiles/ntpcheck.piml
diff -u doc/loncapafiles/ntpcheck.piml:1.41 doc/loncapafiles/ntpcheck.piml:1.42
--- doc/loncapafiles/ntpcheck.piml:1.41	Mon Oct 28 16:34:48 2019
+++ doc/loncapafiles/ntpcheck.piml	Tue Dec  3 04:55:10 2019
@@ -3,7 +3,7 @@
 <!-- ntpcheck.piml -->
 <!-- Matthew Hall -->
 
-<!-- $Id: ntpcheck.piml,v 1.41 2019/10/28 16:34:48 raeburn Exp $ -->
+<!-- $Id: ntpcheck.piml,v 1.42 2019/12/03 04:55:10 raeburn Exp $ -->
 
 <!--
 
@@ -41,13 +41,14 @@
     ('<DIST />' eq 'fedora30') || ('<DIST />' eq 'fedora31') ||
     ('<DIST />' eq 'sles15')   || ('<DIST />' eq 'centos8')  || 
     ('<DIST />' eq 'rhes8')    || ('<DIST />' eq 'oracle7')  ||
-    ('<DIST />' eq 'oracle8')) {
+    ('<DIST />' eq 'oracle8')  || ('<DIST />' eq 'ubuntu18')) {
     print "For more information on chronyd please see https://chrony.tuxfamily.org/\n";
 } else {
     print "For more information on ntpd please see http://www.ntp.org/\n";
 }
 my $NTPD;
 my $name = 'ntp';
+my $binname = $name;
 my $checkcmd = 'ps -ef |grep ntp |grep -v grep |grep -v ntpcheck';
 my $startntpcmd;
 my $is_running;
@@ -67,7 +68,9 @@
     ('<DIST />' eq 'oracle8')) {
     $NTPD = 'ntpd';
     if ('<DIST />' eq 'ubuntu18') {
-        $NTPD = 'ntp';
+        $NTPD = 'chrony';
+        $name = $NTPD;
+        $binname = 'chronyd';  
     } elsif (('<DIST />' eq 'fedora26') || ('<DIST />' eq 'fedora27') ||
              ('<DIST />' eq 'fedora28') || ('<DIST />' eq 'fedora29') ||
              ('<DIST />' eq 'fedora30') || ('<DIST />' eq 'fedora31') ||
@@ -76,10 +79,11 @@
              ('<DIST />' eq 'oracle8')) {
         $NTPD = 'chronyd';
         $name = $NTPD;
+        $binname = $NTPD;
     }
     $checkcmd = "systemctl is-enabled $NTPD.service";
     $startntpcmd = "systemctl start $NTPD.service";
-    if (!-e "/usr/sbin/$NTPD") {
+    if (!-e "/usr/sbin/$binname") {
         print "$name is not installed.\n";
         exit;
     }




More information about the LON-CAPA-cvs mailing list