Bug 753418

Summary: SwapError: swapon failed for '/dev/sda7'
Product: [Fedora] Fedora Reporter: Marco Cyriacks <marco>
Component: anacondaAssignee: Anaconda Maintenance Team <anaconda-maint-list>
Status: CLOSED INSUFFICIENT_DATA QA Contact: Fedora Extras Quality Assurance <extras-qa>
Severity: unspecified Docs Contact:
Priority: unspecified    
Version: 16CC: 416365416c, alvaro393cm, anaconda-maint-list, cs066, damion.c.hancock, dcantrell, dejan1, giannigazia, jivenso, john.kirker, jonathan, kirdyashov, mfields, nicoescobar258, pandar00, rcon.mail, r.garrett, vanmeeuwen+fedora, vilbradr
Target Milestone: ---   
Target Release: ---   
Hardware: i686   
OS: Unspecified   
Whiteboard: abrt_hash:831e5389988e2ddf3bae0cb27b835655e96201f4cf951a70cadb9dc63c7e6ead
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2012-07-19 21:49:59 UTC Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:

Description Marco Cyriacks 2011-11-12 11:44:53 UTC
libreport version: 2.0.6
executable:     /usr/bin/python
hashmarkername: anaconda
kernel:         3.1.0-7.fc16.i686
product:        Fedora
reason:         SwapError: swapon failed for '/dev/sda7'
time:           Sat Nov 12 12:35:14 2011
version:        16

description:
:The following was filed automatically by anaconda:
:anaconda 16.25 exception report
:Traceback (most recent call first):
:  File "/usr/lib/python2.7/site-packages/pyanaconda/storage/devicelibs/swap.py", line 93, in swapon
:    raise SwapError("swapon failed for '%s'" % device)
:  File "/usr/lib/python2.7/site-packages/pyanaconda/storage/formats/swap.py", line 133, in setup
:    swap.swapon(self.device, priority=self.priority)
:  File "/usr/lib/python2.7/site-packages/pyanaconda/storage/__init__.py", line 2085, in turnOnSwap
:    device.format.setup()
:  File "/usr/lib/python2.7/site-packages/pyanaconda/storage/__init__.py", line 1326, in turnOnSwap
:    upgrading=upgrading)
:  File "/usr/lib/python2.7/site-packages/pyanaconda/packages.py", line 151, in turnOnFilesystems
:    anaconda.storage.turnOnSwap()
:  File "/usr/lib/python2.7/site-packages/pyanaconda/dispatch.py", line 373, in dispatch
:    self.dir = self.steps[self.step].target(self.anaconda)
:  File "/usr/lib/python2.7/site-packages/pyanaconda/dispatch.py", line 241, in go_forward
:    self.dispatch()
:  File "/usr/lib/python2.7/site-packages/pyanaconda/gui.py", line 1201, in nextClicked
:    self.anaconda.dispatch.go_forward()
:SwapError: swapon failed for '/dev/sda7'

Comment 1 Marco Cyriacks 2011-11-12 11:49:16 UTC
I tried to install Fedora 16 to a blank new disc (/dev/sdb). The disc partition layout was choosen by anaconda and the bootloader was selected to be installed on sdb too.

After finishing the partitioning dialog of anaconda the above exception occurs. Obviously anaconda tries to activate the swap partition of my fedora 14 installation on my main disc (/dev/sda) an fails.

Comment 2 Marco Cyriacks 2011-11-13 11:54:14 UTC
The crash is obviously not caused by the second harddisc because I removed the old disc (/dev/sda) today and replaced it with the new one. The same exception is raised although now only one new unformatted harddisc is present as /dev/sda.

During all tests I've disabled the LVM usage and configured anaconda to use the whole disc.

Comment 3 dejan1 2011-11-13 18:14:35 UTC
I am also getting this error which is preventing me from installing Fedora 16 on a new hard drive.
Steps taken:
1) Using Fedora 16 i686 Live default
2) Basic Install
3) Use All Space
4) Use LVM

Kept all default, swap is set to 5216M

Anaconda seems to create all partitions and then fails with following message:

anaconda 16.25 exception report
Traceback (most recent call first):
  File "/usr/lib/python2.7/site-packages/pyanaconda/storage/devicelibs/swap.py", line 93, in swapon
    raise SwapError("swapon failed for '%s'" % device)
  File "/usr/lib/python2.7/site-packages/pyanaconda/storage/formats/swap.py", line 133, in setup
    swap.swapon(self.device, priority=self.priority)
  File "/usr/lib/python2.7/site-packages/pyanaconda/storage/__init__.py", line 2085, in turnOnSwap
    device.format.setup()
  File "/usr/lib/python2.7/site-packages/pyanaconda/storage/__init__.py", line 1326, in turnOnSwap
    upgrading=upgrading)
  File "/usr/lib/python2.7/site-packages/pyanaconda/packages.py", line 151, in turnOnFilesystems
    anaconda.storage.turnOnSwap()
  File "/usr/lib/python2.7/site-packages/pyanaconda/dispatch.py", line 373, in dispatch
    self.dir = self.steps[self.step].target(self.anaconda)
  File "/usr/lib/python2.7/site-packages/pyanaconda/dispatch.py", line 241, in go_forward
    self.dispatch()
  File "/usr/lib/python2.7/site-packages/pyanaconda/gui.py", line 1201, in nextClicked
    self.anaconda.dispatch.go_forward()
SwapError: swapon failed for '/dev/mapper/vg_tordej01-lv_swap'

Local variables in innermost frame:
pagesize: 4096
argv: ['/dev/mapper/vg_tordej01-lv_swap']
priority: None
num: 4096
sig: SWAPSPACE2
rc: 255
device: /dev/mapper/vg_tordej01-lv_swap
fd: 26
...

Comment 4 Marco Cyriacks 2011-11-13 21:21:59 UTC
The problem only occurs when starting anaconda using the live-CD of Fedora 16 and selecting the "Install to disc" option. The installation using the DVD image was successfull for me.

Comment 5 Carl 2011-11-16 00:40:24 UTC
I couldn't find a DVD install to try.  However I did work around the issue by telling the installer to delete my current swap partition and not create a new one.

Comment 6 David Lehman 2011-11-17 15:00:42 UTC
It would be very helpful if any of you could collect /tmp/anaconda-tb-* from the system after the error occurs and attach it to this bug report.

Comment 7 David Lehman 2011-12-06 00:06:12 UTC
We have at least four people either reporting this failure or adding themselves to CC list, but not a single log from a failed attempt showing the problem. I will have to close this report due to insufficient information shortly if nobody provides their logs.