Ubuntu Server Guide
iSCSI Network Configuration
Download 1.23 Mb. Pdf ko'rish
|
ubuntu-server-guide (1)
iSCSI Network Configuration
Before configuring the Logical Units that are going to be accessed by the initiator, it is important to inform the iSCSI service what are the interfaces acting as paths. A straightforward way to do that is by: • configuring the following environment variables $ i s c s i 0 1 _ i p=$ ( i p −4 −o addr show i s c s i 0 1 | s e d −r ’ s : . * ( ( [ 0 − 9 ] { 1 , 3 } \ . ) { 3 } [ 0 − 9 ] { 1 , 3 } ) / . * : \ 1 : ’ ) $ i s c s i 0 2 _ i p=$ ( i p −4 −o addr show i s c s i 0 2 | s e d −r ’ s : . * ( ( [ 0 − 9 ] { 1 , 3 } \ . ) { 3 } [ 0 − 9 ] { 1 , 3 } ) / . * : \ 1 : ’ ) $ i s c s i 0 1 _ m a c=$ ( i p −o l i n k show i s c s i 0 1 | s e d −r ’ s : . * \ s+l i n k / e t h e r (([0 − f ] { 2 } ( \ : | ) ) { 6 } ) . * : \ 1 : g ’ ) $ i s c s i 0 2 _ m a c=$ ( i p −o l i n k show i s c s i 0 2 | s e d −r ’ s : . * \ s+l i n k / e t h e r (([0 − f ] { 2 } ( \ : | ) ) { 6 } ) . * : \ 1 : g ’ ) • configuring iscsi01 interface $ sudo i s c s i a d m −m i f a c e −I i s c s i 0 1 −−op=new New i n t e r f a c e i s c s i 0 1 added $ sudo i s c s i a d m −m i f a c e −I i s c s i 0 1 −−op=update −n i f a c e . hwaddress −v $ i s c s i 0 1 _ m a c i s c s i 0 1 updated . $ sudo i s c s i a d m −m i f a c e −I i s c s i 0 1 −−op=update −n i f a c e . i p a d d r e s s −v $ i s c s i 0 1 _ i p i s c s i 0 1 updated . • configuring iscsi02 interface $ sudo i s c s i a d m −m i f a c e −I i s c s i 0 2 −−op=new New i n t e r f a c e i s c s i 0 2 added $ sudo i s c s i a d m −m i f a c e −I i s c s i 0 2 −−op=update −n i f a c e . hwaddress −v $ i s c s i 0 2 _ m a c i s c s i 0 2 updated . $ sudo i s c s i a d m −m i f a c e −I i s c s i 0 2 −−op=update −n i f a c e . i p a d d r e s s −v $ i s c s i 0 2 _ i p i s c s i 0 2 updated . • discovering the targets $ sudo i s c s i a d m −m d i s c o v e r y −I i s c s i 0 1 −−op=new −−op=d e l −−type s e n d t a r g e t s −−p o r t a l s t o r a g e . i s c s i 0 1 1 0 . 2 5 0 . 9 4 . 9 9 : 3 2 6 0 , 1 i q n .2003 −01. o r g . l i n u x − i s c s i . s t o r a g e . x8664 : sn . 2 c 0 8 4 c 8 3 2 0 c a $ sudo i s c s i a d m −m d i s c o v e r y −I i s c s i 0 2 −−op=new −−op=d e l −−type s e n d t a r g e t s −−p o r t a l s t o r a g e . i s c s i 0 2 1 0 . 2 5 0 . 9 3 . 9 9 : 3 2 6 0 , 1 i q n .2003 −01. o r g . l i n u x − i s c s i . s t o r a g e . x8664 : sn . 2 c 0 8 4 c 8 3 2 0 c a 169 • configuring automatic login $ sudo i s c s i a d m −m node −−op=update −n node . conn [ 0 ] . s t a r t u p −v a u t o m a t i c $ sudo i s c s i a d m −m node −−op=update −n node . s t a r t u p −v a u t o m a t i c • make sure needed services are enabled during OS initialization: $ s y s t e m c t l e n a b l e open− i s c s i S y n c h r o n i z i n g s t a t e o f open− i s c s i . s e r v i c e with SysV s e r v i c e s c r i p t with / l i b / systemd / systemd−sysv− i n s t a l l . E x e c u t i n g : / l i b / systemd / systemd−sysv− i n s t a l l e n a b l e open− i s c s i Created sy m li n k / e t c / systemd / system / i s c s i . s e r v i c e → / l i b / systemd / system / open− i s c s i . s e r v i c e . Created sy m li n k / e t c / systemd / system / s y s i n i t . t a r g e t . wants / open− i s c s i . s e r v i c e → / l i b / systemd / system / open− i s c s i . s e r v i c e . $ s y s t e m c t l e n a b l e i s c s i d S y n c h r o n i z i n g s t a t e o f i s c s i d . s e r v i c e with SysV s e r v i c e s c r i p t with / l i b / systemd / systemd−sysv− i n s t a l l . E x e c u t i n g : / l i b / systemd / systemd−sysv− i n s t a l l e n a b l e i s c s i d Created sy m li n k / e t c / systemd / system / s y s i n i t . t a r g e t . wants / i s c s i d . s e r v i c e → / l i b / systemd / system / i s c s i d . s e r v i c e . • restarting iscsid service $ s y s t e m c t l r e s t a r t i s c s i d . s e r v i c e • and, finally, login in discovered logical units $ sudo i s c s i a d m −m node −− l o g i n a l l=a u t o m a t i c Logging i n t o [ i f a c e : i s c s i 0 2 , t a r g e t : i q n .2003 −01. o r g . l i n u x − i s c s i . s t o r a g e . x8664 : sn . 2 c084c8320ca , p o r t a l : 1 0 . 2 5 0 . 9 3 . 9 9 , 3 2 6 0 ] ( m u l t i p l e ) Logging i n t o [ i f a c e : i s c s i 0 1 , t a r g e t : i q n .2003 −01. o r g . l i n u x − i s c s i . s t o r a g e . x8664 : sn . 2 c084c8320ca , p o r t a l : 1 0 . 2 5 0 . 9 4 . 9 9 , 3 2 6 0 ] ( m u l t i p l e ) Login t o [ i f a c e : i s c s i 0 2 , t a r g e t : i q n .2003 −01. o r g . l i n u x − i s c s i . s t o r a g e . x8664 : sn . 2 c084c8320ca , p o r t a l : 1 0 . 2 5 0 . 9 3 . 9 9 , 3 2 6 0 ] s u c c e s s f u l . Login t o [ i f a c e : i s c s i 0 1 , t a r g e t : i q n .2003 −01. o r g . l i n u x − i s c s i . s t o r a g e . x8664 : sn . 2 c084c8320ca , p o r t a l : 1 0 . 2 5 0 . 9 4 . 9 9 , 3 2 6 0 ] s u c c e s s f u l . Download 1.23 Mb. Do'stlaringiz bilan baham: |
Ma'lumotlar bazasi mualliflik huquqi bilan himoyalangan ©fayllar.org 2024
ma'muriyatiga murojaat qiling
ma'muriyatiga murojaat qiling