Administrator's Manual
Total Page:16
File Type:pdf, Size:1020Kb
Technical Documentation LIO LINUX SCSI TARGET Administrator’s Manual Version: 4.0 Print Date: 6 August 2015 Copyright © 2015 Datera, Inc. LIO Admin Manual Copyright Copyright © 2015 Datera, Inc. All rights reserved. No part of this publication may be reproduced, stored in a retrieval system, or transmitted in any form or by any means, electronic, mechanical, photocopying, recording or otherwise, without the prior written consent of Datera, Inc., 2570 W El Camino Real, Suite 380, Mountain View, CA 94040. Trademarks Datera™, LIO™ and the Datera logo are trademarks of Datera, Inc., which may be registered in some jurisdictions. Microsoft and Windows are trademarks of Microsoft Corp. in the US and other countries, used under license. vSphere is a trademark of VMware Inc. in the US and other countries, used under license. All other trademarks are the property of their respective owners. Changes The material in this document is for information only and is subject to change without notice. While reasonable efforts have been made in the preparation of this document to assure its accuracy, Datera, Inc. assumes no liability resulting from errors or omissions in this document, or from the use of the information contained herein. Datera, Inc. reserves the right to make changes in the product design without reservation and without notification to its users. Disclaimer If this product directs you to copy materials, you must have permissions from the copyright owner of the materials to avoid violating the law, which could results in serious damages and/or remedies. Datera, Inc. 2570 W El Camino Real, Suite 380 Mountain View, CA 94040 www.datera.io Phone: +1-650-384-6284 Email: [email protected] Document: Version 4.0 Print date: 6 August 2015 Language: English Copyright © 2015 Datera i LIO Admin Manual Contents Contents ............................................................................................................................................ 2 1 Introduction ............................................................................................................................... 1 2 Overview ................................................................................................................................... 2 2.1 The LIO Linux Stack ....................................................................................................................... 2 2.2 Fabrics ........................................................................................................................................... 2 2.3 Backstores ..................................................................................................................................... 3 3 RAID Device Setup ...................................................................................................................... 5 3.1 Overview ....................................................................................................................................... 5 3.2 System Management .................................................................................................................... 5 3.3 Creating a RAID Set ....................................................................................................................... 7 3.4 Deleting a RAID Set ....................................................................................................................... 8 3.5 Expanding a RAID Set .................................................................................................................... 8 3.6 Failure Management .................................................................................................................... 9 3.7 Best Practices .............................................................................................................................. 10 4 LVM Setup ............................................................................................................................... 11 4.1 Overview ..................................................................................................................................... 11 4.2 Initializing Disks or Disk Partitions .............................................................................................. 11 4.3 Creating Volume Groups ............................................................................................................ 11 4.4 Creating Logical Volumes............................................................................................................ 11 4.5 Deleting Logical Volumes ............................................................................................................ 11 4.6 Resizing Logical Volumes ............................................................................................................ 11 4.7 Resizing Physical Volumes .......................................................................................................... 12 4.8 Best Practices .............................................................................................................................. 12 5 Targetcli Quick Start Guide ....................................................................................................... 13 5.1 Startup ........................................................................................................................................ 13 5.2 iSCSI ............................................................................................................................................ 14 5.3 Fibre Channel .............................................................................................................................. 16 5.4 InfiniBand/SRP ............................................................................................................................ 18 5.5 InfiniBand/iSER ........................................................................................................................... 19 5.6 Persistence .................................................................................................................................. 21 6 Targetcli Concepts .................................................................................................................... 23 6.1 General ....................................................................................................................................... 23 6.2 Working with Contexts ............................................................................................................... 23 6.3 Command Completion and Help ................................................................................................ 23 6.4 Command Syntax ........................................................................................................................ 24 Copyright © 2015 Datera ii LIO Admin Manual 6.5 Command Chains ........................................................................................................................ 24 6.6 Object Tree ................................................................................................................................. 24 6.7 Creating a LUN and exporting it ................................................................................................. 25 6.8 Object Tree Example ................................................................................................................... 25 6.9 Best Practices .............................................................................................................................. 27 7 Targetcli Commands ................................................................................................................. 28 7.1 The bookmarks Command .......................................................................................................... 28 7.2 The cd Command ........................................................................................................................ 28 7.3 The exit Command ...................................................................................................................... 29 7.4 The get Command ...................................................................................................................... 29 7.5 help Command ........................................................................................................................... 29 7.6 The ls Command ......................................................................................................................... 29 7.7 The pwd Command ..................................................................................................................... 29 7.8 The refresh Command ................................................................................................................ 29 7.9 The set Command ....................................................................................................................... 29 7.10 The status Command .................................................................................................................. 30 7.11 Variable Types ............................................................................................................................ 30 7.12 The global Config Group ............................................................................................................. 30 8 Targetcli Contexts ....................................................................................................................