€•7Œsphinx.addnodes”Œdocument”“”)”}”(Œ rawsource”Œ”Œchildren”]”(Œ translations”Œ LanguagesNode”“”)”}”(hhh]”(hŒ pending_xref”“”)”}”(hhh]”Œdocutils.nodes”ŒText”“”ŒChinese (Simplified)”…””}”Œparent”hsbaŒ attributes”}”(Œids”]”Œclasses”]”Œnames”]”Œdupnames”]”Œbackrefs”]”Œ refdomain”Œstd”Œreftype”Œdoc”Œ reftarget”Œ,/translations/zh_CN/filesystems/smb/cifsroot”Œmodname”NŒ classname”NŒ refexplicit”ˆuŒtagname”hhh ubh)”}”(hhh]”hŒChinese (Traditional)”…””}”hh2sbah}”(h]”h ]”h"]”h$]”h&]”Œ refdomain”h)Œreftype”h+Œ reftarget”Œ,/translations/zh_TW/filesystems/smb/cifsroot”Œmodname”NŒ classname”NŒ refexplicit”ˆuh1hhh ubh)”}”(hhh]”hŒItalian”…””}”hhFsbah}”(h]”h ]”h"]”h$]”h&]”Œ refdomain”h)Œreftype”h+Œ reftarget”Œ,/translations/it_IT/filesystems/smb/cifsroot”Œmodname”NŒ classname”NŒ refexplicit”ˆuh1hhh ubh)”}”(hhh]”hŒJapanese”…””}”hhZsbah}”(h]”h ]”h"]”h$]”h&]”Œ refdomain”h)Œreftype”h+Œ reftarget”Œ,/translations/ja_JP/filesystems/smb/cifsroot”Œmodname”NŒ classname”NŒ refexplicit”ˆuh1hhh ubh)”}”(hhh]”hŒKorean”…””}”hhnsbah}”(h]”h ]”h"]”h$]”h&]”Œ refdomain”h)Œreftype”h+Œ reftarget”Œ,/translations/ko_KR/filesystems/smb/cifsroot”Œmodname”NŒ classname”NŒ refexplicit”ˆuh1hhh ubh)”}”(hhh]”hŒSpanish”…””}”hh‚sbah}”(h]”h ]”h"]”h$]”h&]”Œ refdomain”h)Œreftype”h+Œ reftarget”Œ,/translations/sp_SP/filesystems/smb/cifsroot”Œmodname”NŒ classname”NŒ refexplicit”ˆuh1hhh ubeh}”(h]”h ]”h"]”h$]”h&]”Œcurrent_language”ŒEnglish”uh1h hhŒ _document”hŒsource”NŒline”NubhŒcomment”“”)”}”(hŒ SPDX-License-Identifier: GPL-2.0”h]”hŒ SPDX-License-Identifier: GPL-2.0”…””}”hh£sbah}”(h]”h ]”h"]”h$]”h&]”Œ xml:space”Œpreserve”uh1h¡hhhžhhŸŒF/var/lib/git/docbuild/linux/Documentation/filesystems/smb/cifsroot.rst”h KubhŒsection”“”)”}”(hhh]”(hŒtitle”“”)”}”(hŒ+Mounting root file system via SMB (cifs.ko)”h]”hŒ+Mounting root file system via SMB (cifs.ko)”…””}”(hh»hžhhŸNh Nubah}”(h]”h ]”h"]”h$]”h&]”uh1h¹hh¶hžhhŸh³h KubhŒ paragraph”“”)”}”(hŒ4Written 2019 by Paulo Alcantara ”h]”(hŒ!Written 2019 by Paulo Alcantara <”…””}”(hhËhžhhŸNh NubhŒ reference”“”)”}”(hŒpalcantara@suse.de”h]”hŒpalcantara@suse.de”…””}”(hhÕhžhhŸNh Nubah}”(h]”h ]”h"]”h$]”h&]”Œrefuri”Œmailto:palcantara@suse.de”uh1hÓhhËubhŒ>”…””}”(hhËhžhhŸNh Nubeh}”(h]”h ]”h"]”h$]”h&]”uh1hÉhŸh³h Khh¶hžhubhÊ)”}”(hŒ0Written 2019 by Aurelien Aptel ”h]”(hŒ Written 2019 by Aurelien Aptel <”…””}”(hhïhžhhŸNh NubhÔ)”}”(hŒaaptel@suse.com”h]”hŒaaptel@suse.com”…””}”(hh÷hžhhŸNh Nubah}”(h]”h ]”h"]”h$]”h&]”Œrefuri”Œmailto:aaptel@suse.com”uh1hÓhhïubhŒ>”…””}”(hhïhžhhŸNh Nubeh}”(h]”h ]”h"]”h$]”h&]”uh1hÉhŸh³h K hh¶hžhubhÊ)”}”(hŒlThe CONFIG_CIFS_ROOT option enables experimental root file system support over the SMB protocol via cifs.ko.”h]”hŒlThe CONFIG_CIFS_ROOT option enables experimental root file system support over the SMB protocol via cifs.ko.”…””}”(hjhžhhŸNh Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÉhŸh³h K hh¶hžhubhÊ)”}”(hŒ®It introduces a new kernel command-line option called 'cifsroot=' which will tell the kernel to mount the root file system over the network by utilizing SMB or CIFS protocol.”h]”hŒ²It introduces a new kernel command-line option called ‘cifsroot=’ which will tell the kernel to mount the root file system over the network by utilizing SMB or CIFS protocol.”…””}”(hjhžhhŸNh Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÉhŸh³h Khh¶hžhubhÊ)”}”(hŒŸIn order to mount, the network stack will also need to be set up by using 'ip=' config option. For more details, see Documentation/admin-guide/nfs/nfsroot.rst.”h]”hŒ£In order to mount, the network stack will also need to be set up by using ‘ip=’ config option. For more details, see Documentation/admin-guide/nfs/nfsroot.rst.”…””}”(hj-hžhhŸNh Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÉhŸh³h Khh¶hžhubhÊ)”}”(hXÊA CIFS root mount currently requires the use of SMB1+UNIX Extensions which is only supported by the Samba server. SMB1 is the older deprecated version of the protocol but it has been extended to support POSIX features (See [1]). The equivalent extensions for the newer recommended version of the protocol (SMB3) have not been fully implemented yet which means SMB3 doesn't support some required POSIX file system objects (e.g. block devices, pipes, sockets).”h]”hXÌA CIFS root mount currently requires the use of SMB1+UNIX Extensions which is only supported by the Samba server. SMB1 is the older deprecated version of the protocol but it has been extended to support POSIX features (See [1]). The equivalent extensions for the newer recommended version of the protocol (SMB3) have not been fully implemented yet which means SMB3 doesn’t support some required POSIX file system objects (e.g. block devices, pipes, sockets).”…””}”(hj;hžhhŸNh Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÉhŸh³h Khh¶hžhubhÊ)”}”(hŒÕAs a result, a CIFS root will default to SMB1 for now but the version to use can nonetheless be changed via the 'vers=' mount option. This default will change once the SMB3 POSIX extensions are fully implemented.”h]”hŒÙAs a result, a CIFS root will default to SMB1 for now but the version to use can nonetheless be changed via the ‘vers=’ mount option. This default will change once the SMB3 POSIX extensions are fully implemented.”…””}”(hjIhžhhŸNh Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÉhŸh³h Khh¶hžhubhµ)”}”(hhh]”(hº)”}”(hŒServer configuration”h]”hŒServer configuration”…””}”(hjZhžhhŸNh Nubah}”(h]”h ]”h"]”h$]”h&]”uh1h¹hjWhžhhŸh³h K$ubhÊ)”}”(hŒ]To enable SMB1+UNIX extensions you will need to set these global settings in Samba smb.conf::”h]”hŒ\To enable SMB1+UNIX extensions you will need to set these global settings in Samba smb.conf:”…””}”(hjhhžhhŸNh Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÉhŸh³h K&hjWhžhubhŒ literal_block”“”)”}”(hŒH[global] server min protocol = NT1 unix extension = yes # default”h]”hŒH[global] server min protocol = NT1 unix extension = yes # default”…””}”hjxsbah}”(h]”h ]”h"]”h$]”h&]”h±h²uh1jvhŸh³h K)hjWhžhubeh}”(h]”Œserver-configuration”ah ]”h"]”Œserver configuration”ah$]”h&]”uh1h´hh¶hžhhŸh³h K$ubhµ)”}”(hhh]”(hº)”}”(hŒKernel command line”h]”hŒKernel command line”…””}”(hj‘hžhhŸNh Nubah}”(h]”h ]”h"]”h$]”h&]”uh1h¹hjŽhžhhŸh³h K.ubjw)”}”(hŒroot=/dev/cifs”h]”hŒroot=/dev/cifs”…””}”hjŸsbah}”(h]”h ]”h"]”h$]”h&]”h±h²uh1jvhŸh³h K2hjŽhžhubhÊ)”}”(hŒmThis is just a virtual device that basically tells the kernel to mount the root file system via SMB protocol.”h]”hŒmThis is just a virtual device that basically tells the kernel to mount the root file system via SMB protocol.”…””}”(hj­hžhhŸNh Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÉhŸh³h K4hjŽhžhubjw)”}”(hŒ(cifsroot=///[,options]”h]”hŒ(cifsroot=///[,options]”…””}”hj»sbah}”(h]”h ]”h"]”h$]”h&]”h±h²uh1jvhŸh³h K9hjŽhžhubhÊ)”}”(hŒ‚Enables the kernel to mount the root file system via SMB that are located in the and specified in this option.”h]”hŒ‚Enables the kernel to mount the root file system via SMB that are located in the and specified in this option.”…””}”(hjÉhžhhŸNh Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÉhŸh³h K;hjŽhžhubhÊ)”}”(hŒ>The default mount options are set in fs/smb/client/cifsroot.c.”h]”hŒ>The default mount options are set in fs/smb/client/cifsroot.c.”…””}”(hj×hžhhŸNh Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÉhŸh³h K>hjŽhžhubhŒdefinition_list”“”)”}”(hhh]”(hŒdefinition_list_item”“”)”}”(hŒ&server-ip IPv4 address of the server. ”h]”(hŒterm”“”)”}”(hŒ server-ip”h]”hŒ server-ip”…””}”(hjòhžhhŸNh Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jðhŸh³h KAhjìubhŒ definition”“”)”}”(hhh]”hÊ)”}”(hŒIPv4 address of the server.”h]”hŒIPv4 address of the server.”…””}”(hjhžhhŸNh Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÉhŸh³h KAhjubah}”(h]”h ]”h"]”h$]”h&]”uh1jhjìubeh}”(h]”h ]”h"]”h$]”h&]”uh1jêhŸh³h KAhjçubjë)”}”(hŒ"share Path to SMB share (rootfs). ”h]”(jñ)”}”(hŒshare”h]”hŒshare”…””}”(hj#hžhhŸNh Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jðhŸh³h KDhjubj)”}”(hhh]”hÊ)”}”(hŒPath to SMB share (rootfs).”h]”hŒPath to SMB share (rootfs).”…””}”(hj4hžhhŸNh Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÉhŸh³h KDhj1ubah}”(h]”h ]”h"]”h$]”h&]”uh1jhjubeh}”(h]”h ]”h"]”h$]”h&]”uh1jêhŸh³h KDhjçhžhubjë)”}”(hŒIoptions Optional mount options. For more information, see mount.cifs(8). ”h]”(jñ)”}”(hŒoptions”h]”hŒoptions”…””}”(hjRhžhhŸNh Nubah}”(h]”h ]”h"]”h$]”h&]”uh1jðhŸh³h KGhjNubj)”}”(hhh]”hÊ)”}”(hŒ@Optional mount options. For more information, see mount.cifs(8).”h]”hŒ@Optional mount options. For more information, see mount.cifs(8).”…””}”(hjchžhhŸNh Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÉhŸh³h KGhj`ubah}”(h]”h ]”h"]”h$]”h&]”uh1jhjNubeh}”(h]”h ]”h"]”h$]”h&]”uh1jêhŸh³h KGhjçhžhubeh}”(h]”h ]”h"]”h$]”h&]”uh1jåhjŽhžhhŸh³h Nubeh}”(h]”Œkernel-command-line”ah ]”h"]”Œkernel command line”ah$]”h&]”uh1h´hh¶hžhhŸh³h K.ubhµ)”}”(hhh]”(hº)”}”(hŒExamples”h]”hŒExamples”…””}”(hjŽhžhhŸNh Nubah}”(h]”h ]”h"]”h$]”h&]”uh1h¹hj‹hžhhŸh³h KJubhÊ)”}”(hŒ;Export root file system as a Samba share in smb.conf file::”h]”hŒ:Export root file system as a Samba share in smb.conf file:”…””}”(hjœhžhhŸNh Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÉhŸh³h KLhj‹hžhubjw)”}”(hX+... [linux] path = /path/to/rootfs read only = no guest ok = yes force user = root force group = root browseable = yes writeable = yes admin users = root public = yes create mask = 0777 directory mask = 0777 ...”h]”hX+... [linux] path = /path/to/rootfs read only = no guest ok = yes force user = root force group = root browseable = yes writeable = yes admin users = root public = yes create mask = 0777 directory mask = 0777 ...”…””}”hjªsbah}”(h]”h ]”h"]”h$]”h&]”h±h²uh1jvhŸh³h KNhj‹hžhubhÊ)”}”(hŒRestart smb service::”h]”hŒRestart smb service:”…””}”(hj¸hžhhŸNh Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÉhŸh³h K]hj‹hžhubjw)”}”(hŒ# systemctl restart smb”h]”hŒ# systemctl restart smb”…””}”hjÆsbah}”(h]”h ]”h"]”h$]”h&]”h±h²uh1jvhŸh³h K_hj‹hžhubhÊ)”}”(hŒ^Test it under QEMU on a kernel built with CONFIG_CIFS_ROOT and CONFIG_IP_PNP options enabled::”h]”hŒ]Test it under QEMU on a kernel built with CONFIG_CIFS_ROOT and CONFIG_IP_PNP options enabled:”…””}”(hjÔhžhhŸNh Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÉhŸh³h Kahj‹hžhubjw)”}”(hŒÖ# qemu-system-x86_64 -enable-kvm -cpu host -m 1024 \ -kernel /path/to/linux/arch/x86/boot/bzImage -nographic \ -append "root=/dev/cifs rw ip=dhcp cifsroot=//10.0.2.2/linux,username=foo,password=bar console=ttyS0 3"”h]”hŒÖ# qemu-system-x86_64 -enable-kvm -cpu host -m 1024 \ -kernel /path/to/linux/arch/x86/boot/bzImage -nographic \ -append "root=/dev/cifs rw ip=dhcp cifsroot=//10.0.2.2/linux,username=foo,password=bar console=ttyS0 3"”…””}”hjâsbah}”(h]”h ]”h"]”h$]”h&]”h±h²uh1jvhŸh³h Kdhj‹hžhubhÊ)”}”(hŒ31: https://wiki.samba.org/index.php/UNIX_Extensions”h]”(hŒ1: ”…””}”(hjðhžhhŸNh NubhÔ)”}”(hŒ0https://wiki.samba.org/index.php/UNIX_Extensions”h]”hŒ0https://wiki.samba.org/index.php/UNIX_Extensions”…””}”(hjøhžhhŸNh Nubah}”(h]”h ]”h"]”h$]”h&]”Œrefuri”júuh1hÓhjðubeh}”(h]”h ]”h"]”h$]”h&]”uh1hÉhŸh³h Kihj‹hžhubeh}”(h]”Œexamples”ah ]”h"]”Œexamples”ah$]”h&]”uh1h´hh¶hžhhŸh³h KJubeh}”(h]”Œ)mounting-root-file-system-via-smb-cifs-ko”ah ]”h"]”Œ+mounting root file system via smb (cifs.ko)”ah$]”h&]”uh1h´hhhžhhŸh³h Kubeh}”(h]”h ]”h"]”h$]”h&]”Œsource”h³uh1hŒcurrent_source”NŒ current_line”NŒsettings”Œdocutils.frontend”ŒValues”“”)”}”(h¹NŒ generator”NŒ datestamp”NŒ source_link”NŒ source_url”NŒ toc_backlinks”Œentry”Œfootnote_backlinks”KŒ sectnum_xform”KŒstrip_comments”NŒstrip_elements_with_classes”NŒ strip_classes”NŒ report_level”KŒ halt_level”KŒexit_status_level”KŒdebug”NŒwarning_stream”NŒ traceback”ˆŒinput_encoding”Œ utf-8-sig”Œinput_encoding_error_handler”Œstrict”Œoutput_encoding”Œutf-8”Œoutput_encoding_error_handler”j@Œerror_encoding”Œutf-8”Œerror_encoding_error_handler”Œbackslashreplace”Œ language_code”Œen”Œrecord_dependencies”NŒconfig”NŒ id_prefix”hŒauto_id_prefix”Œid”Œ dump_settings”NŒdump_internals”NŒdump_transforms”NŒdump_pseudo_xml”NŒexpose_internals”NŒstrict_visitor”NŒ_disable_config”NŒ_source”h³Œ _destination”NŒ _config_files”]”Œ7/var/lib/git/docbuild/linux/Documentation/docutils.conf”aŒfile_insertion_enabled”ˆŒ raw_enabled”KŒline_length_limit”M'Œpep_references”NŒ pep_base_url”Œhttps://peps.python.org/”Œpep_file_url_template”Œpep-%04d”Œrfc_references”NŒ rfc_base_url”Œ&https://datatracker.ietf.org/doc/html/”Œ tab_width”KŒtrim_footnote_reference_space”‰Œsyntax_highlight”Œlong”Œ smart_quotes”ˆŒsmartquotes_locales”]”Œcharacter_level_inline_markup”‰Œdoctitle_xform”‰Œ docinfo_xform”KŒsectsubtitle_xform”‰Œ image_loading”Œlink”Œembed_stylesheet”‰Œcloak_email_addresses”ˆŒsection_self_link”‰Œenv”NubŒreporter”NŒindirect_targets”]”Œsubstitution_defs”}”Œsubstitution_names”}”Œrefnames”}”Œrefids”}”Œnameids”}”(jjj‹jˆjˆj…jjuŒ nametypes”}”(j‰j‹‰jˆ‰j‰uh}”(jh¶jˆjWj…jŽjj‹uŒ footnote_refs”}”Œ citation_refs”}”Œ autofootnotes”]”Œautofootnote_refs”]”Œsymbol_footnotes”]”Œsymbol_footnote_refs”]”Œ footnotes”]”Œ citations”]”Œautofootnote_start”KŒsymbol_footnote_start”KŒ id_counter”Œ collections”ŒCounter”“”}”…”R”Œparse_messages”]”Œtransform_messages”]”Œ transformer”NŒ include_log”]”Œ decoration”Nhžhub.