Note: This bug is displayed in read-only format because the product is no longer active in Red Hat Bugzilla.
RHEL Engineering is moving the tracking of its product development work on RHEL 6 through RHEL 9 to Red Hat Jira (issues.redhat.com). If you're a Red Hat customer, please continue to file support cases via the Red Hat customer portal. If you're not, please head to the "RHEL project" in Red Hat Jira and file new tickets here. Individual Bugzilla bugs in the statuses "NEW", "ASSIGNED", and "POST" are being migrated throughout September 2023. Bugs of Red Hat partners with an assigned Engineering Partner Manager (EPM) are migrated in late September as per pre-agreed dates. Bugs against components "kernel", "kernel-rt", and "kpatch" are only migrated if still in "NEW" or "ASSIGNED". If you cannot log in to RH Jira, please consult article #7032570. That failing, please send an e-mail to the RH Jira admins at rh-issues@redhat.com to troubleshoot your issue as a user management inquiry. The email creates a ServiceNow ticket with Red Hat. Individual Bugzilla bugs that are migrated will be moved to status "CLOSED", resolution "MIGRATED", and set with "MigratedToJIRA" in "Keywords". The link to the successor Jira issue will be found under "Links", have a little "two-footprint" icon next to it, and direct you to the "RHEL project" in Red Hat Jira (issue links are of type "https://issues.redhat.com/browse/RHEL-XXXX", where "X" is a digit). This same link will be available in a blue banner at the top of the page informing you that that bug has been migrated.

Bug 695740

Summary: swap partitions should be indicated by UUID
Product: Red Hat Enterprise Linux 6 Reporter: Jan Stodola <jstodola>
Component: anacondaAssignee: David Lehman <dlehman>
Status: CLOSED ERRATA QA Contact: Release Test Team <release-test-team-automation>
Severity: medium Docs Contact:
Priority: medium    
Version: 6.1CC: atodorov
Target Milestone: rcKeywords: Reopened
Target Release: ---   
Hardware: All   
OS: Linux   
Whiteboard:
Fixed In Version: anaconda-13.21.125-1 Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2011-12-06 10:32:15 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:
Bug Depends On:    
Bug Blocks: 670159, 705163    
Attachments:
Description Flags
screenshot of swap warning none

Description Jan Stodola 2011-04-12 14:51:20 UTC
Description of problem:
When creating a swap area on a raw partition, anaconda writes into /etc/fstab its device name:

[root@rtt4 ~]# grep swap /etc/fstab
/dev/sdb1               swap                    swap    defaults        0 0

It would be better to write UUID=.. there:

[root@rtt4 ~]# grep swap /etc/fstab
UUID=bc5dfbff-424d-46b6-b388-17c96e76f969    swap    swap    defaults     0 0


When the order of devices changes (sda <-> sdb), system boots without swap attached.


Version-Release number of selected component (if applicable):
RHEL6.1-20110406.0
anaconda-13.21.111-1.el6

How reproducible:
always

Steps to Reproduce:
1. run graphical installation
2. create custom partitioning with swap on a raw partition (for example /dev/sdb1)
3. finish the installation and check /etc/fstab
  
Actual results:
[root@rtt4 ~]# grep swap /etc/fstab
/dev/sdb1               swap                    swap    defaults        0 0

Expected results:
[root@rtt4 ~]# grep swap /etc/fstab
UUID=bc5dfbff-424d-46b6-b388-17c96e76f969     swap    swap  defaults     0 0

Comment 2 Jan Stodola 2011-04-15 10:10:44 UTC
Tested once more and this is more detailed reproducer:

1. install RHEL-5.7 on two zFCP LUNs, create a swap area on a plain partition (for example sdb2)
2. reboot into RHEL5 system, and run "blkid". The swap partition has no UUID defined:

[root@rtt5 ~]# blkid 
/dev/sdb2: LABEL="SWAP-sdb2" TYPE="swap" 
/dev/sdb1: LABEL="/" UUID="0627e41e-6ab7-44a9-aa30-6bf9a9b74dbf" TYPE="ext3" 
/dev/sda1: LABEL="/boot" UUID="2deb0960-f66d-4a65-8d0a-7b5172db94f6" TYPE="ext3"

3. start installation of RHEL-6.1
4. select custom partitioning, reuse existing partitions for / and /boot, but do not format the swap partition.
5. finish the installation, reboot system and check /etc/fstab

Comment 6 Alexander Todorov 2011-08-10 13:27:40 UTC
Created attachment 517598 [details]
screenshot of swap warning

In anaconda-13.21.126 there's a warning about swap partition not having UUID assigned.

Comment 7 errata-xmlrpc 2011-12-06 10:32:15 UTC
Since the problem described in this bug report should be
resolved in a recent advisory, it has been closed with a
resolution of ERRATA.

For information on the advisory, and where to find the updated
files, follow the link below.

If the solution does not work for you, open a new bug report.

http://rhn.redhat.com/errata/RHBA-2011-1565.html