Bug 573354 - Installation fails with "There was a problem activating the satellite: Could not parse certificate file."
Summary: Installation fails with "There was a problem activating the satellite: Could ...
Keywords:
Status: CLOSED CURRENTRELEASE
Alias: None
Product: Spacewalk
Classification: Community
Component: Installation
Version: 0.9
Hardware: All
OS: Linux
low
high
Target Milestone: ---
Assignee: Michael Mráka
QA Contact: Red Hat Satellite QA List
URL:
Whiteboard:
Depends On:
Blocks: space10
TreeView+ depends on / blocked
 
Reported: 2010-03-14 11:29 UTC by Erik Logtenberg
Modified: 2010-05-10 14:51 UTC (History)
1 user (show)

Fixed In Version:
Clone Of:
Environment:
Last Closed: 2010-05-10 14:51:17 UTC
Embargoed:


Attachments (Terms of Use)

Description Erik Logtenberg 2010-03-14 11:29:07 UTC
Description of problem: Installation of Spacewalk fails during "spacewalk-setup --disconnected" step, with the error message "There was a problem activating the satellite: Could not parse certificate file."

Version-Release number of selected component (if applicable):
This is the nightly candidate, from the following repo:
baseurl=http://miroslav.suchy.cz/spacewalk/nightly-candidate-f12/$basearch/os

Currently this is spacewalk-oracle-0.8.1-1.fc12.noarch, but most spacewalk-backend and other spacewalk-* packages vary from versions 0.9.3 to 0.9.9. The spacewalk-setup binary is from spacewalk-setup-0.8.1-1.fc12.noarch.

How reproducible:
100%.

Steps to Reproduce:
1. Just follow the installation instructions on https://fedorahosted.org/spacewalk/wiki/HowToInstall#InstallingSpacewalk
2. Observe mentioned error.
  
Actual results:
# spacewalk-setup --disconnected

* Setting up Oracle environment.
* Setting up database.
** Database: Setting up database connection.
DB User? spacewalk
DB Password? 
DB SID? xe
DB hostname? localhost
DB port [1521]? 
DB protocol [TCP]? 
** Database: Testing database connection.
** Database: Populating database.
*** Progress: ###########################################################
* Setting up users and groups.
** GPG: Initializing GPG and importing key.
** GPG: Creating /root/.gnupg directory
You must enter an email address.
Admin Email Address? email
* Performing initial configuration.
* Activating Spacewalk.
** Loading Spacewalk Certificate.
** Verifying certificate locally.
There was a problem activating the satellite: Could not parse certificate file.

Expected results:
I expected the results as described in the installation instructions.

Additional info:
Installed on Fedora 12 x86_64 fresh and absolute minimal install, all updates applied. During install I unchecked all optional packages, so theoretically this could just be a dependancy-issue (spacewalk using some binary that's not installed), however the error message wasn't specific enough to be sure.

Comment 1 Erik Logtenberg 2010-03-14 12:18:37 UTC
Repeating the operation doesn't help either. spacewalk-setup does have logic to re-setup, it even shuts down services that may be using the database before repopulating it. Nice :)
Nevertheless it fails at the same point as the first attempt.

Please note that there is another non-fatal error concerning the /var/satellite/systemlogs/audit-review.log file, which cannot be chown'ed. I noticed before that it was difficult to remove this file:

# rm -f /var/satellite/systemlogs/audit-review.log
rm: cannot remove `/var/satellite/systemlogs/audit-review.log': Operation not permitted

I'm not quite sure why this is not permitted. The basic unix permissions seem okay, the posix-acl's too, I put SELinux in permissive state, stopped all possibly relevant services, and still I am unable to remove this file.
However I don't think it has anything to do with the error concerning the parsing of the certificate file.

# spacewalk-setup --disconnected
* Setting up Oracle environment.
* Setting up database.
** Database: Setting up database connection.
DB User? spacewalk
DB Password? 
DB SID? xe
DB hostname? localhost
DB port [1521]? 
DB protocol [TCP]? 
** Database: Testing database connection.
** Database: Populating database.
The Database has schema.  Would you like to clear the database [Y]? Y
** Database: Clearing database.
** Database: Shutting down services that may be using DB: [tomcat5, taskomatic, httpd, jabberd, osa-dispatcher, tsdb_local_queue].
** Database: Services stopped.  Clearing DB.
** Database: Re-populating database.
*** Progress: ###########################################################
* Setting up users and groups.
** GPG: Initializing GPG and importing key.
* Performing initial configuration.
chown: changing ownership of `/var/satellite/systemlogs/audit-review.log': Operation not permitted
* Activating Spacewalk.
** Loading Spacewalk Certificate.
** Verifying certificate locally.
There was a problem activating the satellite: Could not parse certificate file.

Comment 2 Michael Mráka 2010-03-16 09:51:11 UTC
I'm not able to reproduce the bug. It was probably immediately fixed in nightly repo.

Feel free to reopen if problem persits.

Comment 3 Erik Logtenberg 2010-03-17 21:51:52 UTC
Okay, I just updated to the latest nightly version. Amongst other things, yum just updated to these packages:

spacewalk-backend.noarch 0:0.9.10-1.fc12
spacewalk-backend-app.noarch 0:0.9.10-1.fc12
spacewalk-backend-applet.noarch 0:0.9.10-1.fc12
spacewalk-backend-config-files.noarch 0:0.9.10-1.fc12               
spacewalk-backend-config-files-common.noarch 0:0.9.10-1.fc12
spacewalk-backend-config-files-tool.noarch 0:0.9.10-1.fc12
spacewalk-backend-iss.noarch 0:0.9.10-1.fc12
spacewalk-backend-iss-export.noarch 0:0.9.10-1.fc12                 
spacewalk-backend-libs.noarch 0:0.9.10-1.fc12
spacewalk-backend-package-push-server.noarch 0:0.9.10-1.fc12        
spacewalk-backend-server.noarch 0:0.9.10-1.fc12
spacewalk-backend-sql.noarch 0:0.9.10-1.fc12                        
spacewalk-backend-tools.noarch 0:0.9.10-1.fc12
spacewalk-backend-xml-export-libs.noarch 0:0.9.10-1.fc12            
spacewalk-backend-xmlrpc.noarch 0:0.9.10-1.fc12
spacewalk-backend-xp.noarch 0:0.9.10-1.fc12                         
spacewalk-java.noarch 0:0.9.9-1.fc12
spacewalk-java-config.noarch 0:0.9.9-1.fc12                         
spacewalk-java-lib.noarch 0:0.9.9-1.fc12
spacewalk-java-oracle.noarch 0:0.9.9-1.fc12                         
spacewalk-taskomatic.noarch 0:0.9.9-1.fc12

Unfortunately I get the exact same output as before. I disabled SELinux and tried once again, but still the exact same output.
I used strace to figure out what goes wrong, but I can't really tell. This is the last strace output:

write(1, "* Activating Spacewalk.\n", 24* Activating Spacewalk.
) = 24
stat("/usr/share/spacewalk/setup/spacewalk-public.cert", {st_mode=S_IFREG|0644, st_size=1043, ...}) = 0
stat("/usr/share/spacewalk/setup/spacewalk-public.cert", {st_mode=S_IFREG|0644, st_size=1043, ...}) = 0
write(1, "** Loading Spacewalk Certificate"..., 34** Loading Spacewalk Certificate.
) = 34
open("/usr/share/spacewalk/setup/spacewalk-public.cert", O_RDONLY) = 5
ioctl(5, SNDCTL_TMR_TIMEBASE or TCGETS, 0x7ffff0336160) = -1 ENOTTY (Inappropriate ioctl for device)
lseek(5, 0, SEEK_CUR)                   = 0
fstat(5, {st_mode=S_IFREG|0644, st_size=1043, ...}) = 0
fcntl(5, F_SETFD, FD_CLOEXEC)           = 0
fstat(5, {st_mode=S_IFREG|0644, st_size=1043, ...}) = 0
read(5, "<?xml version=\"1.0\" encoding=\"UT"..., 4096) = 1043
read(5, "", 4096)                       = 0
write(1, "** Verifying certificate locally"..., 34** Verifying certificate locally.
) = 34
open("/usr/share/spacewalk/setup/spacewalk-public.cert", O_RDONLY) = 6
ioctl(6, SNDCTL_TMR_TIMEBASE or TCGETS, 0x7ffff0336160) = -1 ENOTTY (Inappropriate ioctl for device)
lseek(6, 0, SEEK_CUR)                   = 0
fstat(6, {st_mode=S_IFREG|0644, st_size=1043, ...}) = 0
fcntl(6, F_SETFD, FD_CLOEXEC)           = 0
read(6, "<?xml version=\"1.0\" encoding=\"UT"..., 4096) = 1043
read(6, "", 4096)                       = 0
close(6)                                = 0
rt_sigprocmask(SIG_BLOCK, [ALRM], [], 8) = 0
rt_sigaction(SIGALRM, {SIG_DFL, [], SA_RESTORER, 0x3145e0f0f0}, {SIG_DFL, [], SA_RESTORER, 0x3145e0f0f0}, 8) = 0
rt_sigprocmask(SIG_SETMASK, [], NULL, 8) = 0
open("/var/log/rhn/rhn-installation.log", O_WRONLY|O_CREAT|O_APPEND, 0666) = 6
lseek(6, 0, SEEK_END)                   = 2727
ioctl(6, SNDCTL_TMR_TIMEBASE or TCGETS, 0x7ffff0336160) = -1 ENOTTY (Inappropriate ioctl for device)
lseek(6, 0, SEEK_CUR)                   = 2727
fstat(6, {st_mode=S_IFREG|0644, st_size=2727, ...}) = 0
fcntl(6, F_SETFD, FD_CLOEXEC)           = 0
ioctl(1, SNDCTL_TMR_TIMEBASE or TCGETS, {B38400 opost isig icanon echo ...}) = 0
rt_sigprocmask(SIG_BLOCK, [ALRM], [], 8) = 0
rt_sigaction(SIGALRM, {0x7f64404b8e80, [], SA_RESTORER, 0x3145e0f0f0}, {SIG_DFL, [], SA_RESTORER, 0x3145e0f0f0}, 8) = 0
rt_sigprocmask(SIG_SETMASK, [], NULL, 8) = 0
alarm(1)                                = 0
pipe([7, 8])                            = 0
ioctl(7, SNDCTL_TMR_TIMEBASE or TCGETS, 0x7ffff0336310) = -1 EINVAL (Invalid argument)
lseek(7, 0, SEEK_CUR)                   = -1 ESPIPE (Illegal seek)
ioctl(8, SNDCTL_TMR_TIMEBASE or TCGETS, 0x7ffff0336310) = -1 EINVAL (Invalid argument)
lseek(8, 0, SEEK_CUR)                   = -1 ESPIPE (Illegal seek)
fcntl(7, F_SETFD, FD_CLOEXEC)           = 0
fcntl(8, F_SETFD, FD_CLOEXEC)           = 0
pipe([9, 10])                           = 0
ioctl(9, SNDCTL_TMR_TIMEBASE or TCGETS, 0x7ffff0336310) = -1 EINVAL (Invalid argument)
lseek(9, 0, SEEK_CUR)                   = -1 ESPIPE (Illegal seek)
ioctl(10, SNDCTL_TMR_TIMEBASE or TCGETS, 0x7ffff0336310) = -1 EINVAL (Invalid argument)
lseek(10, 0, SEEK_CUR)                  = -1 ESPIPE (Illegal seek)
fcntl(9, F_SETFD, FD_CLOEXEC)           = 0
fcntl(10, F_SETFD, FD_CLOEXEC)          = 0
clone(child_stack=0, flags=CLONE_CHILD_CLEARTID|CLONE_CHILD_SETTID|SIGCHLD, child_tidptr=0x7f643ff749d0) = 2373
close(7)                                = 0
close(10)                               = 0
close(8)                                = 0
select(16, [9], NULL, NULL, {10, 0})    = 1 (in [9], left {9, 829569})
read(9, "RHN Management Satellite Entitle"..., 4096) = 427
write(6, "RHN Management Satellite Entitle"..., 427) = 427
select(16, [9], NULL, NULL, {10, 0})    = 1 (in [9], left {9, 986530})
--- SIGCHLD (Child exited) @ 0 (0) ---
read(9, "", 4096)                       = 0
wait4(2373, [{WIFEXITED(s) && WEXITSTATUS(s) == 10}], WNOHANG, NULL) = 2373
close(9)                                = 0
close(6)                                = 0
alarm(0)                                = 1
rt_sigprocmask(SIG_BLOCK, [ALRM], [], 8) = 0
rt_sigaction(SIGALRM, {SIG_DFL, [], SA_RESTORER, 0x3145e0f0f0}, {0x7f64404b8e80, [], SA_RESTORER, 0x3145e0f0f0}, 8) = 0
rt_sigprocmask(SIG_SETMASK, [], NULL, 8) = 0
write(1, "There was a problem activating t"..., 80There was a problem activating the satellite: Could not parse certificate file.
) = 80
stat("/usr/lib64/perl5/vendor_perl/5.10.0/x86_64-linux-thread-multi/auto/DBI/DESTROY.al", 0x11b5130) = -1 ENOENT (No such file or directory)
stat("/usr/local/lib64/perl5/site_perl/5.10.0/x86_64-linux-thread-multi/auto/DBI/DESTROY.al", 0x7ffff03360e0) = -1 ENOENT (No such file or directory)
stat("/usr/local/lib/perl5/site_perl/5.10.0/auto/DBI/DESTROY.al", 0x7ffff03360e0) = -1 ENOENT (No such file or directory)
stat("/usr/lib64/perl5/vendor_perl/5.10.0/x86_64-linux-thread-multi/auto/DBI/DESTROY.al", 0x7ffff03360e0) = -1 ENOENT (No such file or directory)
stat("/usr/lib/perl5/vendor_perl/5.10.0/auto/DBI/DESTROY.al", 0x7ffff03360e0) = -1 ENOENT (No such file or directory)
stat("/usr/lib/perl5/vendor_perl/auto/DBI/DESTROY.al", 0x7ffff03360e0) = -1 ENOENT (No such file or directory)
stat("/usr/lib64/perl5/5.10.0/x86_64-linux-thread-multi/auto/DBI/DESTROY.al", 0x7ffff03360e0) = -1 ENOENT (No such file or directory)
stat("/usr/lib/perl5/5.10.0/auto/DBI/DESTROY.al", 0x7ffff03360e0) = -1 ENOENT (No such file or directory)
stat("/usr/lib/perl5/site_perl/auto/DBI/DESTROY.al", 0x7ffff03360e0) = -1 ENOENT (No such file or directory)
stat("./auto/DBI/DESTROY.al", 0x7ffff03360e0) = -1 ENOENT (No such file or directory)
close(3)                                = 0
close(5)                                = 0
close(4)                                = 0
exit_group(31)                          = ?

Comment 4 Michael Mráka 2010-03-26 09:27:56 UTC
Has been fixed by resigning default cert.

commit e25e8d333126c2f76d1fcb5babddb8b957b36e66
    resigning spacewalk cert

Fixed package - spacewalk-branding-0.9.4-1.

Comment 5 Erik Logtenberg 2010-03-28 18:43:02 UTC
Confirmed, the bug is fixed in the latest package. Thanks!

Comment 6 Michael Mráka 2010-05-10 14:51:17 UTC
This bug has been fixed in Spacewalk 1.0.


Note You need to log in before you can comment on or make changes to this bug.