[{"data":1,"prerenderedAt":1533},["ShallowReactive",2],{"/blog/tag/archlinux":3},[4],{"_path":5,"_dir":6,"_draft":7,"_partial":7,"_locale":8,"title":9,"description":10,"date":11,"tags":12,"excerpt":16,"body":26,"_type":1527,"_id":1528,"_source":1529,"_file":1530,"_stem":1531,"_extension":1532},"/blog/hyperv-install-arch","blog",false,"","Installing Arch Linux on Hyper-V","The Linux kernel has been upgraded to version 7 and now uses Rust extensively, delivering major performance improvements. So I'm setting up the latest Arch Linux virtual machine on Hyper-V to give it a try.","2026-07-12 15:27",[13,14,15],"hyper-v","archlinux","linux",{"type":17,"children":18},"root",[19],{"type":20,"tag":21,"props":22,"children":23},"element","p",{},[24],{"type":25,"value":10},"text",{"type":17,"children":27,"toc":1508},[28,32,39,53,60,108,113,134,139,296,301,305,311,316,376,381,401,406,426,431,434,440,445,487,492,506,511,521,524,530,535,540,581,586,617,620,626,647,653,670,696,702,722,735,764,770,794,799,877,942,948,1024,1030,1047,1059,1065,1098,1103,1108,1127,1132,1135,1141,1149,1163,1171,1212,1215,1221,1226,1267,1330,1333,1339,1502],{"type":20,"tag":21,"props":29,"children":30},{},[31],{"type":25,"value":10},{"type":20,"tag":33,"props":34,"children":36},"h2",{"id":35},"installing-arch-linux",[37],{"type":25,"value":38},"Installing Arch Linux",{"type":20,"tag":21,"props":40,"children":41},{},[42,44,51],{"type":25,"value":43},"I chose the official Arch Linux rolling-release image ",{"type":20,"tag":45,"props":46,"children":48},"code",{"className":47},[],[49],{"type":25,"value":50},"archlinux-x86_64.iso",{"type":25,"value":52},", which is about 1.5GB. I went with a minimal installation, which is well suited as a high-performance development server.",{"type":20,"tag":54,"props":55,"children":57},"h3",{"id":56},"key-points-when-creating-the-hyper-v-vm",[58],{"type":25,"value":59},"Key points when creating the Hyper-V VM",{"type":20,"tag":61,"props":62,"children":63},"ul",{},[64,81,98],{"type":20,"tag":65,"props":66,"children":67},"li",{},[68,74,76],{"type":20,"tag":69,"props":70,"children":71},"strong",{},[72],{"type":25,"value":73},"Generation",{"type":25,"value":75},": Select ",{"type":20,"tag":69,"props":77,"children":78},{},[79],{"type":25,"value":80},"Generation 2 (Gen 2)",{"type":20,"tag":65,"props":82,"children":83},{},[84,89,91,96],{"type":20,"tag":69,"props":85,"children":86},{},[87],{"type":25,"value":88},"Secure Boot",{"type":25,"value":90},": Make sure to ",{"type":20,"tag":69,"props":92,"children":93},{},[94],{"type":25,"value":95},"uncheck \"Enable Secure Boot\"",{"type":25,"value":97}," in the VM settings, otherwise it won't boot",{"type":20,"tag":65,"props":99,"children":100},{},[101,106],{"type":20,"tag":69,"props":102,"children":103},{},[104],{"type":25,"value":105},"Network",{"type":25,"value":107},": Use the default network first, then switch to an internal network later",{"type":20,"tag":21,"props":109,"children":110},{},[111],{"type":25,"value":112},"After starting the VM, you'll enter the command-line Live environment. The official installer script is recommended:",{"type":20,"tag":114,"props":115,"children":119},"pre",{"className":116,"code":117,"language":118,"meta":8,"style":8},"language-bash shiki shiki-themes solarized-light github-dark monokai","archinstall\n","bash",[120],{"type":20,"tag":45,"props":121,"children":122},{"__ignoreMap":8},[123],{"type":20,"tag":124,"props":125,"children":128},"span",{"class":126,"line":127},"line",1,[129],{"type":20,"tag":124,"props":130,"children":132},{"style":131},"--shiki-default:#268BD2;--shiki-dark:#B392F0;--shiki-sepia:#A6E22E",[133],{"type":25,"value":117},{"type":20,"tag":21,"props":135,"children":136},{},[137],{"type":25,"value":138},"Key options to choose:",{"type":20,"tag":140,"props":141,"children":142},"table",{},[143,162],{"type":20,"tag":144,"props":145,"children":146},"thead",{},[147],{"type":20,"tag":148,"props":149,"children":150},"tr",{},[151,157],{"type":20,"tag":152,"props":153,"children":154},"th",{},[155],{"type":25,"value":156},"Option",{"type":20,"tag":152,"props":158,"children":159},{},[160],{"type":25,"value":161},"Recommended value",{"type":20,"tag":163,"props":164,"children":165},"tbody",{},[166,188,207,241,254,277],{"type":20,"tag":148,"props":167,"children":168},{},[169,175],{"type":20,"tag":170,"props":171,"children":172},"td",{},[173],{"type":25,"value":174},"Mirror",{"type":20,"tag":170,"props":176,"children":177},{},[178,180,186],{"type":25,"value":179},"Users in China should pick the Tsinghua / USTC mirror under ",{"type":20,"tag":45,"props":181,"children":183},{"className":182},[],[184],{"type":25,"value":185},"China",{"type":25,"value":187}," to speed up downloads",{"type":20,"tag":148,"props":189,"children":190},{},[191,196],{"type":20,"tag":170,"props":192,"children":193},{},[194],{"type":25,"value":195},"Disk partitioning",{"type":20,"tag":170,"props":197,"children":198},{},[199,201],{"type":25,"value":200},"Choose ",{"type":20,"tag":45,"props":202,"children":204},{"className":203},[],[205],{"type":25,"value":206},"Best-effort default partition layout",{"type":20,"tag":148,"props":208,"children":209},{},[210,215],{"type":20,"tag":170,"props":211,"children":212},{},[213],{"type":25,"value":214},"File system",{"type":20,"tag":170,"props":216,"children":217},{},[218,224,226,232,234,239],{"type":20,"tag":45,"props":219,"children":221},{"className":220},[],[222],{"type":25,"value":223},"ext4",{"type":25,"value":225}," (stable) or ",{"type":20,"tag":45,"props":227,"children":229},{"className":228},[],[230],{"type":25,"value":231},"btrfs",{"type":25,"value":233}," (supports snapshots); ",{"type":20,"tag":45,"props":235,"children":237},{"className":236},[],[238],{"type":25,"value":223},{"type":25,"value":240}," is preferred for VMs",{"type":20,"tag":148,"props":242,"children":243},{},[244,249],{"type":20,"tag":170,"props":245,"children":246},{},[247],{"type":25,"value":248},"Users",{"type":20,"tag":170,"props":250,"children":251},{},[252],{"type":25,"value":253},"Set a password for the root user, then add a regular user and make it a sudo user",{"type":20,"tag":148,"props":255,"children":256},{},[257,262],{"type":20,"tag":170,"props":258,"children":259},{},[260],{"type":25,"value":261},"Profile",{"type":20,"tag":170,"props":263,"children":264},{},[265,266,275],{"type":25,"value":200},{"type":20,"tag":69,"props":267,"children":268},{},[269],{"type":20,"tag":45,"props":270,"children":272},{"className":271},[],[273],{"type":25,"value":274},"Minimal",{"type":25,"value":276}," (headless, high performance)",{"type":20,"tag":148,"props":278,"children":279},{},[280,285],{"type":20,"tag":170,"props":281,"children":282},{},[283],{"type":25,"value":284},"Network configuration",{"type":20,"tag":170,"props":286,"children":287},{},[288,290],{"type":25,"value":289},"Keep the default ",{"type":20,"tag":45,"props":291,"children":293},{"className":292},[],[294],{"type":25,"value":295},"NetworkManager",{"type":20,"tag":21,"props":297,"children":298},{},[299],{"type":25,"value":300},"After installation completes, remove the ISO image and reboot into the new system.",{"type":20,"tag":302,"props":303,"children":304},"hr",{},[],{"type":20,"tag":33,"props":306,"children":308},{"id":307},"installing-ssh",[309],{"type":25,"value":310},"Installing SSH",{"type":20,"tag":21,"props":312,"children":313},{},[314],{"type":25,"value":315},"Once in Arch, install and start SSH:",{"type":20,"tag":114,"props":317,"children":319},{"className":116,"code":318,"language":118,"meta":8,"style":8},"sudo pacman -S openssh\nsudo systemctl enable sshd --now\n",[320],{"type":20,"tag":45,"props":321,"children":322},{"__ignoreMap":8},[323,348],{"type":20,"tag":124,"props":324,"children":325},{"class":126,"line":127},[326,331,337,343],{"type":20,"tag":124,"props":327,"children":328},{"style":131},[329],{"type":25,"value":330},"sudo",{"type":20,"tag":124,"props":332,"children":334},{"style":333},"--shiki-default:#2AA198;--shiki-dark:#9ECBFF;--shiki-sepia:#E6DB74",[335],{"type":25,"value":336}," pacman",{"type":20,"tag":124,"props":338,"children":340},{"style":339},"--shiki-default:#CB4B16;--shiki-dark:#79B8FF;--shiki-sepia:#AE81FF",[341],{"type":25,"value":342}," -S",{"type":20,"tag":124,"props":344,"children":345},{"style":333},[346],{"type":25,"value":347}," openssh\n",{"type":20,"tag":124,"props":349,"children":351},{"class":126,"line":350},2,[352,356,361,366,371],{"type":20,"tag":124,"props":353,"children":354},{"style":131},[355],{"type":25,"value":330},{"type":20,"tag":124,"props":357,"children":358},{"style":333},[359],{"type":25,"value":360}," systemctl",{"type":20,"tag":124,"props":362,"children":363},{"style":333},[364],{"type":25,"value":365}," enable",{"type":20,"tag":124,"props":367,"children":368},{"style":333},[369],{"type":25,"value":370}," sshd",{"type":20,"tag":124,"props":372,"children":373},{"style":339},[374],{"type":25,"value":375}," --now\n",{"type":20,"tag":21,"props":377,"children":378},{},[379],{"type":25,"value":380},"Check the IP address:",{"type":20,"tag":114,"props":382,"children":384},{"className":116,"code":383,"language":118,"meta":8,"style":8},"ip a\n",[385],{"type":20,"tag":45,"props":386,"children":387},{"__ignoreMap":8},[388],{"type":20,"tag":124,"props":389,"children":390},{"class":126,"line":127},[391,396],{"type":20,"tag":124,"props":392,"children":393},{"style":131},[394],{"type":25,"value":395},"ip",{"type":20,"tag":124,"props":397,"children":398},{"style":333},[399],{"type":25,"value":400}," a\n",{"type":20,"tag":21,"props":402,"children":403},{},[404],{"type":25,"value":405},"Then connect from a Windows terminal:",{"type":20,"tag":114,"props":407,"children":409},{"className":116,"code":408,"language":118,"meta":8,"style":8},"ssh username@IP_ADDRESS\n",[410],{"type":20,"tag":45,"props":411,"children":412},{"__ignoreMap":8},[413],{"type":20,"tag":124,"props":414,"children":415},{"class":126,"line":127},[416,421],{"type":20,"tag":124,"props":417,"children":418},{"style":131},[419],{"type":25,"value":420},"ssh",{"type":20,"tag":124,"props":422,"children":423},{"style":333},[424],{"type":25,"value":425}," username@IP_ADDRESS\n",{"type":20,"tag":21,"props":427,"children":428},{},[429],{"type":25,"value":430},"You should be able to connect normally at this point. However, if you're using the default Hyper-V network, the VM's IP may change after a reboot, so it's recommended to configure a static IP.",{"type":20,"tag":302,"props":432,"children":433},{},[],{"type":20,"tag":33,"props":435,"children":437},{"id":436},"creating-a-hyper-v-internal-network",[438],{"type":25,"value":439},"Creating a Hyper-V Internal Network",{"type":20,"tag":21,"props":441,"children":442},{},[443],{"type":25,"value":444},"Open:",{"type":20,"tag":114,"props":446,"children":449},{"className":447,"code":448,"language":25,"meta":8,"style":8},"language-text shiki shiki-themes solarized-light github-dark monokai","Hyper-V Manager\n→ Virtual Switch Manager\n→ New Virtual Switch\n→ Internal\n",[450],{"type":20,"tag":45,"props":451,"children":452},{"__ignoreMap":8},[453,461,469,478],{"type":20,"tag":124,"props":454,"children":455},{"class":126,"line":127},[456],{"type":20,"tag":124,"props":457,"children":458},{},[459],{"type":25,"value":460},"Hyper-V Manager\n",{"type":20,"tag":124,"props":462,"children":463},{"class":126,"line":350},[464],{"type":20,"tag":124,"props":465,"children":466},{},[467],{"type":25,"value":468},"→ Virtual Switch Manager\n",{"type":20,"tag":124,"props":470,"children":472},{"class":126,"line":471},3,[473],{"type":20,"tag":124,"props":474,"children":475},{},[476],{"type":25,"value":477},"→ New Virtual Switch\n",{"type":20,"tag":124,"props":479,"children":481},{"class":126,"line":480},4,[482],{"type":20,"tag":124,"props":483,"children":484},{},[485],{"type":25,"value":486},"→ Internal\n",{"type":20,"tag":21,"props":488,"children":489},{},[490],{"type":25,"value":491},"For example, name it:",{"type":20,"tag":114,"props":493,"children":495},{"className":447,"code":494,"language":25,"meta":8,"style":8},"VM-Internal\n",[496],{"type":20,"tag":45,"props":497,"children":498},{"__ignoreMap":8},[499],{"type":20,"tag":124,"props":500,"children":501},{"class":126,"line":127},[502],{"type":20,"tag":124,"props":503,"children":504},{},[505],{"type":25,"value":494},{"type":20,"tag":21,"props":507,"children":508},{},[509],{"type":25,"value":510},"After creation, you also need to go into the VM settings and switch the network adapter to this new virtual switch.",{"type":20,"tag":21,"props":512,"children":513},{},[514,519],{"type":20,"tag":69,"props":515,"children":516},{},[517],{"type":25,"value":518},"Note",{"type":25,"value":520},": Switching the network will immediately drop the existing SSH connection, so it's recommended to finish the Windows-side network configuration first, then switch the VM's network.",{"type":20,"tag":302,"props":522,"children":523},{},[],{"type":20,"tag":33,"props":525,"children":527},{"id":526},"configuring-windows-nat",[528],{"type":25,"value":529},"Configuring Windows NAT",{"type":20,"tag":21,"props":531,"children":532},{},[533],{"type":25,"value":534},"Open PowerShell as Administrator:",{"type":20,"tag":21,"props":536,"children":537},{},[538],{"type":25,"value":539},"Configure the gateway address for the virtual network adapter created by Hyper-V:",{"type":20,"tag":114,"props":541,"children":545},{"className":542,"code":543,"language":544,"meta":8,"style":8},"language-powershell shiki shiki-themes solarized-light github-dark monokai","New-NetIPAddress `\n  -IPAddress 192.168.100.1 `\n  -PrefixLength 24 `\n  -InterfaceAlias \"vEthernet (VM-Internal)\"\n","powershell",[546],{"type":20,"tag":45,"props":547,"children":548},{"__ignoreMap":8},[549,557,565,573],{"type":20,"tag":124,"props":550,"children":551},{"class":126,"line":127},[552],{"type":20,"tag":124,"props":553,"children":554},{},[555],{"type":25,"value":556},"New-NetIPAddress `\n",{"type":20,"tag":124,"props":558,"children":559},{"class":126,"line":350},[560],{"type":20,"tag":124,"props":561,"children":562},{},[563],{"type":25,"value":564},"  -IPAddress 192.168.100.1 `\n",{"type":20,"tag":124,"props":566,"children":567},{"class":126,"line":471},[568],{"type":20,"tag":124,"props":569,"children":570},{},[571],{"type":25,"value":572},"  -PrefixLength 24 `\n",{"type":20,"tag":124,"props":574,"children":575},{"class":126,"line":480},[576],{"type":20,"tag":124,"props":577,"children":578},{},[579],{"type":25,"value":580},"  -InterfaceAlias \"vEthernet (VM-Internal)\"\n",{"type":20,"tag":21,"props":582,"children":583},{},[584],{"type":25,"value":585},"Create the NAT:",{"type":20,"tag":114,"props":587,"children":589},{"className":542,"code":588,"language":544,"meta":8,"style":8},"New-NetNat `\n  -Name \"VM-NAT\" `\n  -InternalIPInterfaceAddressPrefix \"192.168.100.0/24\"\n",[590],{"type":20,"tag":45,"props":591,"children":592},{"__ignoreMap":8},[593,601,609],{"type":20,"tag":124,"props":594,"children":595},{"class":126,"line":127},[596],{"type":20,"tag":124,"props":597,"children":598},{},[599],{"type":25,"value":600},"New-NetNat `\n",{"type":20,"tag":124,"props":602,"children":603},{"class":126,"line":350},[604],{"type":20,"tag":124,"props":605,"children":606},{},[607],{"type":25,"value":608},"  -Name \"VM-NAT\" `\n",{"type":20,"tag":124,"props":610,"children":611},{"class":126,"line":471},[612],{"type":20,"tag":124,"props":613,"children":614},{},[615],{"type":25,"value":616},"  -InternalIPInterfaceAddressPrefix \"192.168.100.0/24\"\n",{"type":20,"tag":302,"props":618,"children":619},{},[],{"type":20,"tag":33,"props":621,"children":623},{"id":622},"configuring-a-static-ip-on-arch-linux",[624],{"type":25,"value":625},"Configuring a Static IP on Arch Linux",{"type":20,"tag":21,"props":627,"children":628},{},[629,631,637,639,645],{"type":25,"value":630},"Arch Linux uses ",{"type":20,"tag":45,"props":632,"children":634},{"className":633},[],[635],{"type":25,"value":636},"systemd-networkd",{"type":25,"value":638}," to manage networking, and configuration files live in ",{"type":20,"tag":45,"props":640,"children":642},{"className":641},[],[643],{"type":25,"value":644},"/etc/systemd/network/",{"type":25,"value":646},".",{"type":20,"tag":54,"props":648,"children":650},{"id":649},"_1-check-the-network-interface-name",[651],{"type":25,"value":652},"1. Check the network interface name",{"type":20,"tag":114,"props":654,"children":655},{"className":116,"code":383,"language":118,"meta":8,"style":8},[656],{"type":20,"tag":45,"props":657,"children":658},{"__ignoreMap":8},[659],{"type":20,"tag":124,"props":660,"children":661},{"class":126,"line":127},[662,666],{"type":20,"tag":124,"props":663,"children":664},{"style":131},[665],{"type":25,"value":395},{"type":20,"tag":124,"props":667,"children":668},{"style":333},[669],{"type":25,"value":400},{"type":20,"tag":21,"props":671,"children":672},{},[673,675,681,683,689,690],{"type":25,"value":674},"Common names: ",{"type":20,"tag":45,"props":676,"children":678},{"className":677},[],[679],{"type":25,"value":680},"eth0",{"type":25,"value":682},", ",{"type":20,"tag":45,"props":684,"children":686},{"className":685},[],[687],{"type":25,"value":688},"ens160",{"type":25,"value":682},{"type":20,"tag":45,"props":691,"children":693},{"className":692},[],[694],{"type":25,"value":695},"enp0s3",{"type":20,"tag":54,"props":697,"children":699},{"id":698},"_2-inspect-and-clean-up-existing-configuration",[700],{"type":25,"value":701},"2. Inspect and clean up existing configuration",{"type":20,"tag":114,"props":703,"children":705},{"className":116,"code":704,"language":118,"meta":8,"style":8},"ls /etc/systemd/network/\n",[706],{"type":20,"tag":45,"props":707,"children":708},{"__ignoreMap":8},[709],{"type":20,"tag":124,"props":710,"children":711},{"class":126,"line":127},[712,717],{"type":20,"tag":124,"props":713,"children":714},{"style":131},[715],{"type":25,"value":716},"ls",{"type":20,"tag":124,"props":718,"children":719},{"style":333},[720],{"type":25,"value":721}," /etc/systemd/network/\n",{"type":20,"tag":21,"props":723,"children":724},{},[725,727,733],{"type":25,"value":726},"If a DHCP config file exists (e.g. ",{"type":20,"tag":45,"props":728,"children":730},{"className":729},[],[731],{"type":25,"value":732},"10-eth0.network",{"type":25,"value":734},"), delete or back it up first to avoid conflicts with the static config (systemd loads files in filename order and matches the first one):",{"type":20,"tag":114,"props":736,"children":738},{"className":116,"code":737,"language":118,"meta":8,"style":8},"sudo mv /etc/systemd/network/10-eth0.network /etc/systemd/network/10-eth0.network.bak\n",[739],{"type":20,"tag":45,"props":740,"children":741},{"__ignoreMap":8},[742],{"type":20,"tag":124,"props":743,"children":744},{"class":126,"line":127},[745,749,754,759],{"type":20,"tag":124,"props":746,"children":747},{"style":131},[748],{"type":25,"value":330},{"type":20,"tag":124,"props":750,"children":751},{"style":333},[752],{"type":25,"value":753}," mv",{"type":20,"tag":124,"props":755,"children":756},{"style":333},[757],{"type":25,"value":758}," /etc/systemd/network/10-eth0.network",{"type":20,"tag":124,"props":760,"children":761},{"style":333},[762],{"type":25,"value":763}," /etc/systemd/network/10-eth0.network.bak\n",{"type":20,"tag":54,"props":765,"children":767},{"id":766},"_3-create-the-static-ip-config-file",[768],{"type":25,"value":769},"3. Create the static IP config file",{"type":20,"tag":114,"props":771,"children":773},{"className":116,"code":772,"language":118,"meta":8,"style":8},"sudo vim /etc/systemd/network/20-wired.network\n",[774],{"type":20,"tag":45,"props":775,"children":776},{"__ignoreMap":8},[777],{"type":20,"tag":124,"props":778,"children":779},{"class":126,"line":127},[780,784,789],{"type":20,"tag":124,"props":781,"children":782},{"style":131},[783],{"type":25,"value":330},{"type":20,"tag":124,"props":785,"children":786},{"style":333},[787],{"type":25,"value":788}," vim",{"type":20,"tag":124,"props":790,"children":791},{"style":333},[792],{"type":25,"value":793}," /etc/systemd/network/20-wired.network\n",{"type":20,"tag":21,"props":795,"children":796},{},[797],{"type":25,"value":798},"Write the following content (adjust the IP according to your setup):",{"type":20,"tag":114,"props":800,"children":804},{"className":801,"code":802,"language":803,"meta":8,"style":8},"language-ini shiki shiki-themes solarized-light github-dark monokai","[Match]\nName=eth0\n\n[Network]\nAddress=192.168.100.10/24\nGateway=192.168.100.1\nDNS=1.1.1.1\nDNS=8.8.8.8\n","ini",[805],{"type":20,"tag":45,"props":806,"children":807},{"__ignoreMap":8},[808,816,824,833,841,850,859,868],{"type":20,"tag":124,"props":809,"children":810},{"class":126,"line":127},[811],{"type":20,"tag":124,"props":812,"children":813},{},[814],{"type":25,"value":815},"[Match]\n",{"type":20,"tag":124,"props":817,"children":818},{"class":126,"line":350},[819],{"type":20,"tag":124,"props":820,"children":821},{},[822],{"type":25,"value":823},"Name=eth0\n",{"type":20,"tag":124,"props":825,"children":826},{"class":126,"line":471},[827],{"type":20,"tag":124,"props":828,"children":830},{"emptyLinePlaceholder":829},true,[831],{"type":25,"value":832},"\n",{"type":20,"tag":124,"props":834,"children":835},{"class":126,"line":480},[836],{"type":20,"tag":124,"props":837,"children":838},{},[839],{"type":25,"value":840},"[Network]\n",{"type":20,"tag":124,"props":842,"children":844},{"class":126,"line":843},5,[845],{"type":20,"tag":124,"props":846,"children":847},{},[848],{"type":25,"value":849},"Address=192.168.100.10/24\n",{"type":20,"tag":124,"props":851,"children":853},{"class":126,"line":852},6,[854],{"type":20,"tag":124,"props":855,"children":856},{},[857],{"type":25,"value":858},"Gateway=192.168.100.1\n",{"type":20,"tag":124,"props":860,"children":862},{"class":126,"line":861},7,[863],{"type":20,"tag":124,"props":864,"children":865},{},[866],{"type":25,"value":867},"DNS=1.1.1.1\n",{"type":20,"tag":124,"props":869,"children":871},{"class":126,"line":870},8,[872],{"type":20,"tag":124,"props":873,"children":874},{},[875],{"type":25,"value":876},"DNS=8.8.8.8\n",{"type":20,"tag":878,"props":879,"children":880},"blockquote",{},[881,891],{"type":20,"tag":21,"props":882,"children":883},{},[884,889],{"type":20,"tag":69,"props":885,"children":886},{},[887],{"type":25,"value":888},"Important",{"type":25,"value":890},":",{"type":20,"tag":61,"props":892,"children":893},{},[894,905,924],{"type":20,"tag":65,"props":895,"children":896},{},[897,903],{"type":20,"tag":45,"props":898,"children":900},{"className":899},[],[901],{"type":25,"value":902},"Name",{"type":25,"value":904}," must match the interface name exactly",{"type":20,"tag":65,"props":906,"children":907},{},[908,910,916,918],{"type":25,"value":909},"Use the ",{"type":20,"tag":45,"props":911,"children":913},{"className":912},[],[914],{"type":25,"value":915},"/24",{"type":25,"value":917}," format for the subnet mask, not ",{"type":20,"tag":45,"props":919,"children":921},{"className":920},[],[922],{"type":25,"value":923},"255.255.255.0",{"type":20,"tag":65,"props":925,"children":926},{},[927,940],{"type":20,"tag":69,"props":928,"children":929},{},[930,932,938],{"type":25,"value":931},"Do not add any ",{"type":20,"tag":45,"props":933,"children":935},{"className":934},[],[936],{"type":25,"value":937},"#",{"type":25,"value":939}," comments or non-ASCII characters",{"type":25,"value":941},", otherwise systemd-networkd may fail to parse the file",{"type":20,"tag":54,"props":943,"children":945},{"id":944},"_4-enable-and-restart-the-network-service",[946],{"type":25,"value":947},"4. Enable and restart the network service",{"type":20,"tag":114,"props":949,"children":951},{"className":116,"code":950,"language":118,"meta":8,"style":8},"sudo systemctl enable systemd-networkd --now\nsudo systemctl enable systemd-resolved --now\nsudo systemctl restart systemd-networkd\n",[952],{"type":20,"tag":45,"props":953,"children":954},{"__ignoreMap":8},[955,979,1003],{"type":20,"tag":124,"props":956,"children":957},{"class":126,"line":127},[958,962,966,970,975],{"type":20,"tag":124,"props":959,"children":960},{"style":131},[961],{"type":25,"value":330},{"type":20,"tag":124,"props":963,"children":964},{"style":333},[965],{"type":25,"value":360},{"type":20,"tag":124,"props":967,"children":968},{"style":333},[969],{"type":25,"value":365},{"type":20,"tag":124,"props":971,"children":972},{"style":333},[973],{"type":25,"value":974}," systemd-networkd",{"type":20,"tag":124,"props":976,"children":977},{"style":339},[978],{"type":25,"value":375},{"type":20,"tag":124,"props":980,"children":981},{"class":126,"line":350},[982,986,990,994,999],{"type":20,"tag":124,"props":983,"children":984},{"style":131},[985],{"type":25,"value":330},{"type":20,"tag":124,"props":987,"children":988},{"style":333},[989],{"type":25,"value":360},{"type":20,"tag":124,"props":991,"children":992},{"style":333},[993],{"type":25,"value":365},{"type":20,"tag":124,"props":995,"children":996},{"style":333},[997],{"type":25,"value":998}," systemd-resolved",{"type":20,"tag":124,"props":1000,"children":1001},{"style":339},[1002],{"type":25,"value":375},{"type":20,"tag":124,"props":1004,"children":1005},{"class":126,"line":471},[1006,1010,1014,1019],{"type":20,"tag":124,"props":1007,"children":1008},{"style":131},[1009],{"type":25,"value":330},{"type":20,"tag":124,"props":1011,"children":1012},{"style":333},[1013],{"type":25,"value":360},{"type":20,"tag":124,"props":1015,"children":1016},{"style":333},[1017],{"type":25,"value":1018}," restart",{"type":20,"tag":124,"props":1020,"children":1021},{"style":333},[1022],{"type":25,"value":1023}," systemd-networkd\n",{"type":20,"tag":54,"props":1025,"children":1027},{"id":1026},"_5-confirm-the-ip",[1028],{"type":25,"value":1029},"5. Confirm the IP",{"type":20,"tag":114,"props":1031,"children":1032},{"className":116,"code":383,"language":118,"meta":8,"style":8},[1033],{"type":20,"tag":45,"props":1034,"children":1035},{"__ignoreMap":8},[1036],{"type":20,"tag":124,"props":1037,"children":1038},{"class":126,"line":127},[1039,1043],{"type":20,"tag":124,"props":1040,"children":1041},{"style":131},[1042],{"type":25,"value":395},{"type":20,"tag":124,"props":1044,"children":1045},{"style":333},[1046],{"type":25,"value":400},{"type":20,"tag":21,"props":1048,"children":1049},{},[1050,1052,1058],{"type":25,"value":1051},"It should now show ",{"type":20,"tag":45,"props":1053,"children":1055},{"className":1054},[],[1056],{"type":25,"value":1057},"inet 192.168.100.10/24",{"type":25,"value":646},{"type":20,"tag":54,"props":1060,"children":1062},{"id":1061},"_6-test-the-network",[1063],{"type":25,"value":1064},"6. Test the network",{"type":20,"tag":114,"props":1066,"children":1068},{"className":116,"code":1067,"language":118,"meta":8,"style":8},"ping 1.1.1.1\nping google.com\n",[1069],{"type":20,"tag":45,"props":1070,"children":1071},{"__ignoreMap":8},[1072,1086],{"type":20,"tag":124,"props":1073,"children":1074},{"class":126,"line":127},[1075,1080],{"type":20,"tag":124,"props":1076,"children":1077},{"style":131},[1078],{"type":25,"value":1079},"ping",{"type":20,"tag":124,"props":1081,"children":1083},{"style":1082},"--shiki-default:#D33682;--shiki-dark:#79B8FF;--shiki-sepia:#AE81FF",[1084],{"type":25,"value":1085}," 1.1.1.1\n",{"type":20,"tag":124,"props":1087,"children":1088},{"class":126,"line":350},[1089,1093],{"type":20,"tag":124,"props":1090,"children":1091},{"style":131},[1092],{"type":25,"value":1079},{"type":20,"tag":124,"props":1094,"children":1095},{"style":333},[1096],{"type":25,"value":1097}," google.com\n",{"type":20,"tag":21,"props":1099,"children":1100},{},[1101],{"type":25,"value":1102},"If you can reach the internet normally, the NAT and DNS configuration are working.",{"type":20,"tag":21,"props":1104,"children":1105},{},[1106],{"type":25,"value":1107},"From now on you can connect using the fixed address:",{"type":20,"tag":114,"props":1109,"children":1111},{"className":116,"code":1110,"language":118,"meta":8,"style":8},"ssh username@192.168.100.10\n",[1112],{"type":20,"tag":45,"props":1113,"children":1114},{"__ignoreMap":8},[1115],{"type":20,"tag":124,"props":1116,"children":1117},{"class":126,"line":127},[1118,1122],{"type":20,"tag":124,"props":1119,"children":1120},{"style":131},[1121],{"type":25,"value":420},{"type":20,"tag":124,"props":1123,"children":1124},{"style":333},[1125],{"type":25,"value":1126}," username@192.168.100.10\n",{"type":20,"tag":21,"props":1128,"children":1129},{},[1130],{"type":25,"value":1131},"without worrying about the IP changing.",{"type":20,"tag":302,"props":1133,"children":1134},{},[],{"type":20,"tag":33,"props":1136,"children":1138},{"id":1137},"configuring-passwordless-login",[1139],{"type":25,"value":1140},"Configuring Passwordless Login",{"type":20,"tag":61,"props":1142,"children":1143},{},[1144],{"type":20,"tag":65,"props":1145,"children":1146},{},[1147],{"type":25,"value":1148},"Generate an SSH key pair on Windows (skip this if you've already generated one before):",{"type":20,"tag":114,"props":1150,"children":1152},{"className":542,"code":1151,"language":544,"meta":8,"style":8},"ssh-keygen -t rsa -b 4096\n",[1153],{"type":20,"tag":45,"props":1154,"children":1155},{"__ignoreMap":8},[1156],{"type":20,"tag":124,"props":1157,"children":1158},{"class":126,"line":127},[1159],{"type":20,"tag":124,"props":1160,"children":1161},{},[1162],{"type":25,"value":1151},{"type":20,"tag":61,"props":1164,"children":1165},{},[1166],{"type":20,"tag":65,"props":1167,"children":1168},{},[1169],{"type":25,"value":1170},"Copy the public key to Arch Linux:",{"type":20,"tag":114,"props":1172,"children":1174},{"className":116,"code":1173,"language":118,"meta":8,"style":8},"cat ~/.ssh/id_rsa.pub | ssh username@192.168.100.10 \"mkdir -p ~/.ssh && cat >> ~/.ssh/authorized_keys\"\n",[1175],{"type":20,"tag":45,"props":1176,"children":1177},{"__ignoreMap":8},[1178],{"type":20,"tag":124,"props":1179,"children":1180},{"class":126,"line":127},[1181,1186,1191,1197,1202,1207],{"type":20,"tag":124,"props":1182,"children":1183},{"style":131},[1184],{"type":25,"value":1185},"cat",{"type":20,"tag":124,"props":1187,"children":1188},{"style":333},[1189],{"type":25,"value":1190}," ~/.ssh/id_rsa.pub",{"type":20,"tag":124,"props":1192,"children":1194},{"style":1193},"--shiki-default:#859900;--shiki-dark:#F97583;--shiki-sepia:#F92672",[1195],{"type":25,"value":1196}," |",{"type":20,"tag":124,"props":1198,"children":1199},{"style":131},[1200],{"type":25,"value":1201}," ssh",{"type":20,"tag":124,"props":1203,"children":1204},{"style":333},[1205],{"type":25,"value":1206}," username@192.168.100.10",{"type":20,"tag":124,"props":1208,"children":1209},{"style":333},[1210],{"type":25,"value":1211}," \"mkdir -p ~/.ssh && cat >> ~/.ssh/authorized_keys\"\n",{"type":20,"tag":302,"props":1213,"children":1214},{},[],{"type":20,"tag":33,"props":1216,"children":1218},{"id":1217},"bonus-installing-basic-tools",[1219],{"type":25,"value":1220},"Bonus: Installing Basic Tools",{"type":20,"tag":21,"props":1222,"children":1223},{},[1224],{"type":25,"value":1225},"A minimal system lacks some common tools, so it's recommended to install them:",{"type":20,"tag":114,"props":1227,"children":1229},{"className":116,"code":1228,"language":118,"meta":8,"style":8},"sudo pacman -S git less vim fish\n",[1230],{"type":20,"tag":45,"props":1231,"children":1232},{"__ignoreMap":8},[1233],{"type":20,"tag":124,"props":1234,"children":1235},{"class":126,"line":127},[1236,1240,1244,1248,1253,1258,1262],{"type":20,"tag":124,"props":1237,"children":1238},{"style":131},[1239],{"type":25,"value":330},{"type":20,"tag":124,"props":1241,"children":1242},{"style":333},[1243],{"type":25,"value":336},{"type":20,"tag":124,"props":1245,"children":1246},{"style":339},[1247],{"type":25,"value":342},{"type":20,"tag":124,"props":1249,"children":1250},{"style":333},[1251],{"type":25,"value":1252}," git",{"type":20,"tag":124,"props":1254,"children":1255},{"style":333},[1256],{"type":25,"value":1257}," less",{"type":20,"tag":124,"props":1259,"children":1260},{"style":333},[1261],{"type":25,"value":788},{"type":20,"tag":124,"props":1263,"children":1264},{"style":333},[1265],{"type":25,"value":1266}," fish\n",{"type":20,"tag":61,"props":1268,"children":1269},{},[1270,1281,1300,1319],{"type":20,"tag":65,"props":1271,"children":1272},{},[1273,1279],{"type":20,"tag":45,"props":1274,"children":1276},{"className":1275},[],[1277],{"type":25,"value":1278},"git",{"type":25,"value":1280},": version control",{"type":20,"tag":65,"props":1282,"children":1283},{},[1284,1290,1292,1298],{"type":20,"tag":45,"props":1285,"children":1287},{"className":1286},[],[1288],{"type":25,"value":1289},"less",{"type":25,"value":1291},": Git pager (otherwise ",{"type":20,"tag":45,"props":1293,"children":1295},{"className":1294},[],[1296],{"type":25,"value":1297},"git log",{"type":25,"value":1299}," will error out)",{"type":20,"tag":65,"props":1301,"children":1302},{},[1303,1309,1311,1317],{"type":20,"tag":45,"props":1304,"children":1306},{"className":1305},[],[1307],{"type":25,"value":1308},"vim",{"type":25,"value":1310}," or ",{"type":20,"tag":45,"props":1312,"children":1314},{"className":1313},[],[1315],{"type":25,"value":1316},"nano",{"type":25,"value":1318},": text editor",{"type":20,"tag":65,"props":1320,"children":1321},{},[1322,1328],{"type":20,"tag":45,"props":1323,"children":1325},{"className":1324},[],[1326],{"type":25,"value":1327},"fish",{"type":25,"value":1329},": a friendly interactive shell (optional)",{"type":20,"tag":302,"props":1331,"children":1332},{},[],{"type":20,"tag":33,"props":1334,"children":1336},{"id":1335},"faq",[1337],{"type":25,"value":1338},"FAQ",{"type":20,"tag":140,"props":1340,"children":1341},{},[1342,1358],{"type":20,"tag":144,"props":1343,"children":1344},{},[1345],{"type":20,"tag":148,"props":1346,"children":1347},{},[1348,1353],{"type":20,"tag":152,"props":1349,"children":1350},{},[1351],{"type":25,"value":1352},"Problem",{"type":20,"tag":152,"props":1354,"children":1355},{},[1356],{"type":25,"value":1357},"Solution",{"type":20,"tag":163,"props":1359,"children":1360},{},[1361,1377,1393,1430,1470],{"type":20,"tag":148,"props":1362,"children":1363},{},[1364,1372],{"type":20,"tag":170,"props":1365,"children":1366},{},[1367],{"type":20,"tag":69,"props":1368,"children":1369},{},[1370],{"type":25,"value":1371},"Still boots into the installer after reboot",{"type":20,"tag":170,"props":1373,"children":1374},{},[1375],{"type":25,"value":1376},"Remove the ISO image from the VM",{"type":20,"tag":148,"props":1378,"children":1379},{},[1380,1388],{"type":20,"tag":170,"props":1381,"children":1382},{},[1383],{"type":20,"tag":69,"props":1384,"children":1385},{},[1386],{"type":25,"value":1387},"Doesn't boot into the system after reboot",{"type":20,"tag":170,"props":1389,"children":1390},{},[1391],{"type":25,"value":1392},"Move the disk to the first position in the boot order",{"type":20,"tag":148,"props":1394,"children":1395},{},[1396,1404],{"type":20,"tag":170,"props":1397,"children":1398},{},[1399],{"type":20,"tag":69,"props":1400,"children":1401},{},[1402],{"type":25,"value":1403},"Static IP not taking effect",{"type":20,"tag":170,"props":1405,"children":1406},{},[1407,1409,1415,1417,1423,1425],{"type":25,"value":1408},"Check for conflicting ",{"type":20,"tag":45,"props":1410,"children":1412},{"className":1411},[],[1413],{"type":25,"value":1414},".network",{"type":25,"value":1416}," files (e.g. files prefixed with ",{"type":20,"tag":45,"props":1418,"children":1420},{"className":1419},[],[1421],{"type":25,"value":1422},"10-",{"type":25,"value":1424}," have higher priority); remove the conflicting file and restart ",{"type":20,"tag":45,"props":1426,"children":1428},{"className":1427},[],[1429],{"type":25,"value":636},{"type":20,"tag":148,"props":1431,"children":1432},{},[1433,1452],{"type":20,"tag":170,"props":1434,"children":1435},{},[1436],{"type":20,"tag":69,"props":1437,"children":1438},{},[1439,1444,1446],{"type":20,"tag":45,"props":1440,"children":1442},{"className":1441},[],[1443],{"type":25,"value":1297},{"type":25,"value":1445}," errors with ",{"type":20,"tag":45,"props":1447,"children":1449},{"className":1448},[],[1450],{"type":25,"value":1451},"cannot run less",{"type":20,"tag":170,"props":1453,"children":1454},{},[1455,1457,1462,1464],{"type":25,"value":1456},"Install ",{"type":20,"tag":45,"props":1458,"children":1460},{"className":1459},[],[1461],{"type":25,"value":1289},{"type":25,"value":1463},": ",{"type":20,"tag":45,"props":1465,"children":1467},{"className":1466},[],[1468],{"type":25,"value":1469},"sudo pacman -S less",{"type":20,"tag":148,"props":1471,"children":1472},{},[1473,1489],{"type":20,"tag":170,"props":1474,"children":1475},{},[1476],{"type":20,"tag":69,"props":1477,"children":1478},{},[1479,1481,1487],{"type":25,"value":1480},"No network but ",{"type":20,"tag":45,"props":1482,"children":1484},{"className":1483},[],[1485],{"type":25,"value":1486},"ip a",{"type":25,"value":1488}," shows an IP",{"type":20,"tag":170,"props":1490,"children":1491},{},[1492,1494,1500],{"type":25,"value":1493},"Check the DNS configuration and make sure ",{"type":20,"tag":45,"props":1495,"children":1497},{"className":1496},[],[1498],{"type":25,"value":1499},"systemd-resolved",{"type":25,"value":1501}," is enabled",{"type":20,"tag":1503,"props":1504,"children":1505},"style",{},[1506],{"type":25,"value":1507},"html .default .shiki span {color: var(--shiki-default);background: var(--shiki-default-bg);font-style: var(--shiki-default-font-style);font-weight: var(--shiki-default-font-weight);text-decoration: var(--shiki-default-text-decoration);}html .shiki span {color: var(--shiki-default);background: var(--shiki-default-bg);font-style: var(--shiki-default-font-style);font-weight: var(--shiki-default-font-weight);text-decoration: var(--shiki-default-text-decoration);}html .dark .shiki span {color: var(--shiki-dark);background: var(--shiki-dark-bg);font-style: var(--shiki-dark-font-style);font-weight: var(--shiki-dark-font-weight);text-decoration: var(--shiki-dark-text-decoration);}html.dark .shiki span {color: var(--shiki-dark);background: var(--shiki-dark-bg);font-style: var(--shiki-dark-font-style);font-weight: var(--shiki-dark-font-weight);text-decoration: var(--shiki-dark-text-decoration);}html .sepia .shiki span {color: var(--shiki-sepia);background: var(--shiki-sepia-bg);font-style: var(--shiki-sepia-font-style);font-weight: var(--shiki-sepia-font-weight);text-decoration: var(--shiki-sepia-text-decoration);}html.sepia .shiki span {color: var(--shiki-sepia);background: var(--shiki-sepia-bg);font-style: var(--shiki-sepia-font-style);font-weight: var(--shiki-sepia-font-weight);text-decoration: var(--shiki-sepia-text-decoration);}",{"title":8,"searchDepth":350,"depth":350,"links":1509},[1510,1513,1514,1515,1516,1524,1525,1526],{"id":35,"depth":350,"text":38,"children":1511},[1512],{"id":56,"depth":471,"text":59},{"id":307,"depth":350,"text":310},{"id":436,"depth":350,"text":439},{"id":526,"depth":350,"text":529},{"id":622,"depth":350,"text":625,"children":1517},[1518,1519,1520,1521,1522,1523],{"id":649,"depth":471,"text":652},{"id":698,"depth":471,"text":701},{"id":766,"depth":471,"text":769},{"id":944,"depth":471,"text":947},{"id":1026,"depth":471,"text":1029},{"id":1061,"depth":471,"text":1064},{"id":1137,"depth":350,"text":1140},{"id":1217,"depth":350,"text":1220},{"id":1335,"depth":350,"text":1338},"markdown","content:blog:971.hyperv-install-arch.md","content","blog/971.hyperv-install-arch.md","blog/971.hyperv-install-arch","md",1783843574493]