On rhel5 ,you should edit following both files:

1./etc/sysconfig/rawdevices

   
   
   
   
  1. # raw device bindings 
  2. # format:  <rawdev> <major> <minor> 
  3. #          <rawdev> <blockdev> 
  4. # example: /dev/raw/raw1 /dev/sda1 
  5. #          /dev/raw/raw2 8 5 
  6. /dev/raw/raw1 /dev/mapper/datavg-vol01 
  7. /dev/raw/raw2 /dev/mapper/datavg-vol02 
  8. /dev/raw/raw3 /dev/mapper/datavg-vol03 
  9. /dev/raw/raw4 /dev/mapper/datavg-vol04 
  10. /dev/raw/raw5 /dev/mapper/datavg-vol05 
  11. /dev/raw/raw6 /dev/mapper/datavg-vol06 

2./etc/udev/rules.d/60-raw.rules

   
   
   
   
  1. ACTION=="add", KERNEL=="raw[1-6]", OWNER="sybase"GROUP="sybase"MODE="660" 

3.Restart rawdevices service

   
   
   
   
  1. [root@syb05 ~]# service rawdevices restart 

On rhel6,you just edit /etc/udev/rules.d/60-raw.rules file

   
   
   
   
  1. ACTION=="add", KERNEL=="dm-1", OWNER=="sybuser", GROUP=="sybase", RUN+="/bin/raw /dev/raw/raw1 %N" 
  2. ACTION=="add", KERNEL=="dm-2", OWNER=="sybuser", GROUP=="sybase", RUN+="/bin/raw /dev/raw/raw2 %N" 
  3. ACTION=="add", KERNEL=="dm-3", OWNER=="sybuser", GROUP=="sybase", RUN+="/bin/raw /dev/raw/raw3 %N" 
  4. ACTION=="add", KERNEL=="raw[1-3]", OWNER="sybuser"GROUP="sybase"MODE="660" 
   
   
   
   
  1. [root@syb06 ~]# start_udev