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 734794

Summary: RHEL6.1 i386 ami does not have swap partitions
Product: Red Hat Enterprise Linux 6 Reporter: wes hayutin <whayutin>
Component: relengAssignee: Jay Greguske <jgreguske>
Status: CLOSED DUPLICATE QA Contact: wes hayutin <whayutin>
Severity: unspecified Docs Contact:
Priority: unspecified    
Version: 6.2CC: dmach, drjones, pbonzini
Target Milestone: rcKeywords: EC2
Target Release: ---   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2011-12-13 15:36:50 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: 756082    

Description wes hayutin 2011-08-31 13:41:57 UTC
Description of problem:

[root@ip-10-242-203-226 ~]# wget -q -O - http://169.254.169.254/latest/dynamic/instance-identity/document
{
  "version" : "2010-08-31",
  "kernelId" : "aki-36ed075f",
  "ramdiskId" : null,
  "instanceId" : "i-c833d4a8",
  "instanceType" : "m1.small",
  "architecture" : "i386",
  "billingProducts" : [ "bp-6fa54006" ],
  "availabilityZone" : "us-east-1b",
  "accountId" : "673500695950",
  "pendingTime" : "2011-08-31T12:05:36Z",
  "devpayProductCodes" : null,
  "imageId" : "ami-0cbb4265",
  "privateIp" : "10.242.203.226",
  "region" : "us-east-1"
}[root@ip-10-242-203-226 ~]# cat /etc/fstab 
LABEL=_/   /         ext4    defaults        1 1
/dev/xvda2 /mnt      ext3    defaults,context=system_u:object_r:usr_t:s0  0 0
/dev/xvda3 swap      swap    defaults        0 0
none       /proc     proc    defaults        0 0
none       /sys      sysfs   defaults        0 0
none       /dev/pts  devpts  gid=5,mode=620  0 0
none       /dev/shm  tmpfs   defaults        0 0
[root@ip-10-242-203-226 ~]# swapon -a
swapon: /dev/xvda3: stat failed: No such file or directory
[root@ip-10-242-203-226 ~]# 



I will try to get info on the other hwp for i386, however I'm assuming small and medium have the same issue

Comment 2 Jay Greguske 2011-08-31 14:14:18 UTC
It'd be helpful to see if this a problem on RHEL 5.

RHEL 6 has a bug where xen devices start from 'e' rather than 'a'.

https://bugzilla.redhat.com/show_bug.cgi?id=729586

So /dev/xvda3 is actually being exposed as /dev/xvde3. In my trial if you change that swap fstab entry to match this behavior, swapon -a works.

RHEL 5 doesn't have this bug, so it should just work.

Comment 3 Jay Greguske 2011-08-31 14:15:48 UTC
Additionally when filing an ec2-related bug, please be sure to use the EC2 keyword.

Comment 4 Andrew Jones 2011-10-05 14:49:12 UTC
Why do AMI fstab files use devices instead of labels or uuids? I think a bug to the instance generator should be written to correct that. These types of assumptions about device naming are dangerous and unnecessary.

Comment 5 Paolo Bonzini 2011-10-06 11:20:31 UTC
In addition, /dev/xvda is _not_ being exposed as /dev/xvde, /dev/sda is.

The problem really is that we are using /dev/sda.  Is that mandated by Amazon's infrastructure or can we control this?

Comment 6 Jay Greguske 2011-10-06 13:00:46 UTC
/dev/sda is what Amazon's docs recommend. Other Linux distributions as far as I know use this convention.

http://docs.amazonwebservices.com/AWSEC2/latest/UserGuide/InstanceStorage.html

Comment 11 Jay Greguske 2011-12-13 15:36:50 UTC
Closing as a dupe since this is really a symptom of bug 729586.

*** This bug has been marked as a duplicate of bug 729586 ***