--- doc/install/linux/install.pl 2019/05/26 22:23:25 1.54 +++ doc/install/linux/install.pl 2019/07/02 19:40:35 1.55 @@ -77,7 +77,7 @@ if (!open(LOG,">>loncapa_install.log")) &mt('Stopping execution.')."\n"; exit; } else { - print LOG '$Id: install.pl,v 1.54 2019/05/26 22:23:25 raeburn Exp $'."\n"; + print LOG '$Id: install.pl,v 1.55 2019/07/02 19:40:35 raeburn Exp $'."\n"; } # @@ -166,7 +166,18 @@ sub get_user_selection { sub get_distro { my ($distro,$gotprereqs,$updatecmd,$packagecmd,$installnow,$unknown); $packagecmd = '/bin/rpm -q LONCAPA-prerequisites '; - if (-e '/etc/redhat-release') { + if (-e '/etc/oracle-release') { + open(IN,'; + chomp($versionstring); + close(IN); + if ($versionstring =~ /^Oracle Linux Server release (\d+)/) { + my $version = $1; + $distro = 'oracle'.$1; + $updatecmd = 'yum install LONCAPA-prerequisites'; + $installnow = 'yum -y install LONCAPA-prerequisites'; + } + } elsif (-e '/etc/redhat-release') { open(IN,'; chomp($versionstring); @@ -312,7 +323,7 @@ sub get_distro { $unknown = 1; } } else { - print &mt('Unknown installation: expecting a debian, ubuntu, suse, sles, redhat, fedora or scientific linux system.')."\n"; + print &mt('Unknown installation: expecting a debian, ubuntu, suse, sles, redhat, fedora, scientific linux, or oracle linux system.')."\n"; } } return ($distro,$packagecmd,$updatecmd,$installnow);