In addition to Weibo, there is also WeChat
Please pay attention
WeChat public account
Shulou
2025-04-16 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Servers >
Share
Shulou(Shulou.com)06/01 Report--
How to bind the permissions of Centos7 multipath disk. In view of this problem, this article introduces the corresponding analysis and solution in detail, hoping to help more partners who want to solve this problem to find a more simple and easy way.
Centos7 multipath disk permission binding.
[root@centos7 ~] $more / etc/udev/rules.d/99-oracle.rules
KERNEL== "dm-0", OWNER= "oragrid", GROUP= "dba", MODE= "0660"
KERNEL== "dm-1", OWNER= "oragrid", GROUP= "dba", MODE= "0660"
KERNEL== "dm-2", OWNER= "oragrid", GROUP= "dba", MODE= "0660"
KERNEL== "dm-3", OWNER= "oragrid", GROUP= "dba", MODE= "0660"
KERNEL== "dm-4", OWNER= "oragrid", GROUP= "dba", MODE= "0660"
KERNEL== "dm-5", OWNER= "oragrid", GROUP= "dba", MODE= "0660"
KERNEL== "dm-6", OWNER= "oragrid", GROUP= "dba", MODE= "0660"
KERNEL== "dm-7", OWNER= "oragrid", GROUP= "dba", MODE= "0660"
KERNEL== "dm-8", OWNER= "oragrid", GROUP= "dba", MODE= "0660"
KERNEL== "dm-9", OWNER= "oragrid", GROUP= "dba", MODE= "0660"
The corresponding relationship before the shutdown
[root@centos7 ~] $ls-l / dev/mapper/
Total 0
Crw-. 1 root root 10, 236 Jan 26 12:18 control
Lrwxrwxrwx. 1 root root 7 Jan 29 08:06 data01->.. / dm-3
Lrwxrwxrwx. 1 root root 7 Jan 29 08:06 data02->.. / dm-0
Lrwxrwxrwx. 1 root root 7 Jan 26 11:35 data03->.. / dm-1
Lrwxrwxrwx. 1 root root 7 Jan 29 08:06 data04->.. / dm-4
Lrwxrwxrwx. 1 root root 7 Jan 29 08:06 fra01->.. / dm-5
Lrwxrwxrwx. 1 root root 7 Jan 26 11:35 fra02->.. / dm-6
Lrwxrwxrwx. 1 root root 7 Jan 26 11:35 ocr01->.. / dm-8
Lrwxrwxrwx. 1 root root 7 Jan 26 11:35 ocr02->.. / dm-7
Lrwxrwxrwx. 1 root root 7 Jan 26 11:35 ocr03->.. / dm-9
Lrwxrwxrwx. 1 root root 8 Jan 26 12:18 ocr04->.. / dm-10
Lrwxrwxrwx. 1 root root 7 Jan 26 11:35 virtual->.. / dm-2
Lrwxrwxrwx. 1 root root 8 Jan 26 12:18 virtual1->.. / dm-11
After reboot. The correspondence has changed. As follows:
Dm-3 is required for data01 restart, and dm-2 is required after restart.
[root@centos7 ~] $ls-l / dev/mapper/
Total 0
Crw-. 1 root root 10, 236 Jan 29 2018 control
Lrwxrwxrwx. 1 root root 7 Jan 29 2018 data01->.. / dm-2
Lrwxrwxrwx. 1 root root 7 Jan 29 2018 data02->.. / dm-4
Lrwxrwxrwx. 1 root root 7 Jan 29 2018 data03->.. / dm-5
Lrwxrwxrwx. 1 root root 7 Jan 29 2018 data04->.. / dm-7
Lrwxrwxrwx. 1 root root 7 Jan 29 2018 fra01->.. / dm-3
Lrwxrwxrwx. 1 root root 7 Jan 29 2018 fra02->.. / dm-0
Lrwxrwxrwx. 1 root root 7 Jan 29 2018 ocr01->.. / dm-1
Lrwxrwxrwx. 1 root root 7 Jan 29 2018 ocr02->.. / dm-8
Lrwxrwxrwx. 1 root root 8 Jan 29 2018 ocr03->.. / dm-10
Lrwxrwxrwx. 1 root root 7 Jan 29 2018 ocr04->.. / dm-9
Lrwxrwxrwx. 1 root root 7 Jan 29 2018 virtual->.. / dm-6
Lrwxrwxrwx. 1 root root 8 Jan 29 2018 virtual1->.. / dm-11
So KERNEL== "dm-0", OWNER= "oragrid", GROUP= "dba", MODE= "0660"
There is a problem with the way permissions are bound.
If it happens not to be bound to. Permissions cannot be granted normally.
Bind permissions in the following way.
[root@centos7 / etc/udev/rules.d] $more 99-oracle.rules
PROGRAM= "/ usr/bin/chown oragrid:dba / dev/mapper/ocr01"
PROGRAM= "/ usr/bin/chown oragrid:dba / dev/mapper/ocr02"
PROGRAM= "/ usr/bin/chown oragrid:dba / dev/mapper/ocr03"
PROGRAM= "/ usr/bin/chown oragrid:dba / dev/mapper/ocr04"
PROGRAM= "/ usr/bin/chown oragrid:dba / dev/mapper/data01"
PROGRAM= "/ usr/bin/chown oragrid:dba / dev/mapper/data02"
PROGRAM= "/ usr/bin/chown oragrid:dba / dev/mapper/data03"
PROGRAM= "/ usr/bin/chown oragrid:dba / dev/mapper/data04"
PROGRAM= "/ usr/bin/chown oragrid:dba / dev/mapper/fra01"
PROGRAM= "/ usr/bin/chown oragrid:dba / dev/mapper/fra02"
PROGRAM= "/ usr/bin/chmod 0660 / dev/mapper/ocr01"
PROGRAM= "/ usr/bin/chmod 0660 / dev/mapper/ocr02"
PROGRAM= "/ usr/bin/chmod 0660 / dev/mapper/ocr03"
PROGRAM= "/ usr/bin/chmod 0660 / dev/mapper/ocr04"
PROGRAM= "/ usr/bin/chmod 0660 / dev/mapper/data01"
PROGRAM= "/ usr/bin/chmod 0660 / dev/mapper/data02"
PROGRAM= "/ usr/bin/chmod 0660 / dev/mapper/data03"
PROGRAM= "/ usr/bin/chmod 0660 / dev/mapper/data04"
PROGRAM= "/ usr/bin/chmod 0660 / dev/mapper/fra01"
PROGRAM= "/ usr/bin/chmod 0660 / dev/mapper/fra02"
Check the permissions after reboot, and the permissions of the disk used by ASM are normal.
[root@centos7 / etc/udev/rules.d] $ls-l / dev/mapper/
Total 0
Crw-. 1 root root 10, 236 Jan 29 2018 control
Lrwxrwxrwx. 1 root root 7 Jan 29 09:47 data01->.. / dm-3
Lrwxrwxrwx. 1 root root 7 Jan 29 09:47 data02->.. / dm-5
Lrwxrwxrwx. 1 root root 7 Jan 29 09:41 data03->.. / dm-4
Lrwxrwxrwx. 1 root root 7 Jan 29 09:47 data04->.. / dm-2
Lrwxrwxrwx. 1 root root 7 Jan 29 09:47 fra01->.. / dm-6
Lrwxrwxrwx. 1 root root 7 Jan 29 09:41 fra02->.. / dm-0
Lrwxrwxrwx. 1 root root 7 Jan 29 09:41 ocr01->.. / dm-7
Lrwxrwxrwx. 1 root root 7 Jan 29 09:41 ocr02->.. / dm-8
Lrwxrwxrwx. 1 root root 8 Jan 29 09:41 ocr03->.. / dm-10
Lrwxrwxrwx. 1 root root 7 Jan 29 09:41 ocr04->.. / dm-9
Lrwxrwxrwx. 1 root root 7 Jan 29 2018 virtual->.. / dm-1
Lrwxrwxrwx. 1 root root 8 Jan 29 2018 virtual1->.. / dm-11
[root@centos7 / etc/udev/rules.d] $ls-l / dev/dm*
Brw-rw----. 1 oragrid dba 253, 0 Jan 29 09:41 / dev/dm-0
Brw-rw----. 1 root disk 253, 1 Jan 29 2018 / dev/dm-1
Brw-rw----. 1 oragrid dba 253, 10 Jan 29 09:41 / dev/dm-10
Brw-rw----. 1 root disk 253, 11 Jan 29 2018 / dev/dm-11
Brw-rw----. 1 oragrid dba 253, 2 Jan 29 09:47 / dev/dm-2
Brw-rw----. 1 oragrid dba 253, 3 Jan 29 09:51 / dev/dm-3
Brw-rw----. 1 oragrid dba 253, 4 Jan 29 09:41 / dev/dm-4
Brw-rw----. 1 oragrid dba 253, 5 Jan 29 09:51 / dev/dm-5
Brw-rw----. 1 oragrid dba 253, 6 Jan 29 09:51 / dev/dm-6
Brw-rw----. 1 oragrid dba 253, 7 Jan 29 09:51 / dev/dm-7
Brw-rw----. 1 oragrid dba 253, 8 Jan 29 09:51 / dev/dm-8
Brw-rw----. 1 oragrid dba 253, 9 Jan 29 09:41 / dev/dm-9
Chown,chmod plus the full path of the command.
About how to bind the permissions of Centos7 multipath disk. The answer to the question is shared here. I hope the above content can be of some help to you. If you still have a lot of doubts to be solved, you can follow the industry information channel to learn more about it.
Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.
Views: 0
*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.
Continue with the installation of the previous hadoop.First, install zookooper1. Decompress zookoope
"Every 5-10 years, there's a rare product, a really special, very unusual product that's the most un
© 2024 shulou.com SLNews company. All rights reserved.