virtualmin-base-5.0-1.rh.noarch.rpm pre-install script bug


Downloading Packages:
virtualmin-base-5.0-1.rh.noarch.rpm | 37 kB 00:00
Running rpm_check_debug
...
...
Configuring Dovecot for POP3 and IMAP
Enabling Dovecot POP3 and IMAP servers
Enabling SFTP on port 2222 in ProFTPd
Error occurred while enabling SFTP in ProFTPd: Can't locate object method "priny" via package "IO::Handle" at /var/tmp/rpm-tmp.IR6fKD line 297.
Enabling ProFTPd
Starting proftpd: [ OK ]


# ProFTPd
# Enable SFTP
eval {
print "Enabling SFTP on port 2222 in ProFTPd\n";
open(my $fh, '>>', '/etc/proftpd.conf');
print $fh "\nLoadModule mod_sftp.c\n";
print $fh "\n\n";
print $fh " SFTPEngine on\n";
print $fh " Port 2222\n";
print $fh " SFTPLog /var/log/proftpd/sftp.log\n\n";
print $fh " SFTPHostKey /etc/ssh/ssh_host_rsa_key\n";
print $fh " SFTPHostKey /etc/ssh/ssh_host_dsa_key\n\n";
priny $fh " SFTPAuthorizedUserKeys file:~/.sftp/authorized_keys\n\n";
print $fh " SFTPCompression delayed\n\n";
print $fh "\n";
close $fh;
}
or do {
print "Error occurred while enabling SFTP in ProFTPd: $@\n";
};
# Start service
eval {
print "Enabling ProFTPd\n";
init::enable_at_boot("proftpd");
:297

Status: 
Closed (fixed)

Comments

Howdy -- thanks for letting us know!

What distro/version does that issue occur on?

And did the installation fail at that point?

Joe's picture
Submitted by Joe on Sun, 01/10/2016 - 17:21 Pro Licensee

I see the problem, and will be rolling a new virtualmin-base package in a couple of hours. It shouldn't stop the installation, but will lead to a slightly messed up ProFTPd configuration. I didn't notice in my tests, because I don't usually use FTP. Thanks for the heads up!

will be rolling a new virtualmin-base package in a couple of hours

1 month 3 weeks

ping)

Hmm, are you using Virtualmin Pro or GPL on this server? And is it 32 or 64 bit?

Hmm, are you still experiencing this issue? If so, I'll talk to Joe and see what the status is.

are you still experiencing this issue?

What changed? virtualmin-base have not any update since 2016-01-06.

$ date
Wed Apr 27 02:46:12 CEST 2016
$ wget http://software.virtualmin.com/gpl/rhel/6/x86_64/virtualmin-base-5.0-1.rh.noarch.rpm
$ rpm -qp --scripts  virtualmin-base-5.0-1.rh.noarch.rpm| grep priny
warning: virtualmin-base-5.0-1.rh.noarch.rpm: Header V4 DSA/SHA1 Signature, key ID a0bdbcf9: NOKEY
priny $fh "    SFTPAuthorizedUserKeys file:~/.sftp/authorized_keys\n\n";
$

up.

Have same problem.

6 months passed, but this was not corrected.

Virtualmin project closed?

I'll ask Joe to take a look into this and follow up with this request.

Joe's picture
Submitted by Joe on Sat, 06/18/2016 - 17:35 Pro Licensee

Hmmm...not sure why that old version is still in some repos. It should have been replaced at the same time it happened for the Pro repos. I guess my deployment scripts are still broken after the migration.

Oh, I see. I guess this update didn't get rolled out for old RHEL/CentOS versions. not sure why. It was fixed in 5.0-3 which was rolled out months ago, but it missed some repos. Fixed now.

Joe's picture
Submitted by Joe on Sat, 06/18/2016 - 17:55 Pro Licensee

Status: Active » Fixed

Marking this fixed, as I think it actually is now. Holler if the problem persists; I don't have a CentOS 5 or 6 system handy to test on at the moment, so, feedback on those is particularly useful.

I don't have a CentOS 5 or 6 system handy to test on at the moment,

i think, virtualmin-base-5.0-4.rh.noarch.rpm is the same for all RHEL/CentOS versions. the bug is fixed. i checked rpms for CentOS 6 & 7.