{"id":26717,"date":"2022-12-27T12:27:42","date_gmt":"2022-12-27T11:27:42","guid":{"rendered":"https:\/\/ekiwi-blog.de\/26717\/mklink-zugriff-verweigert\/"},"modified":"2022-12-27T14:40:25","modified_gmt":"2022-12-27T13:40:25","slug":"mklink-access-is-denied","status":"publish","type":"post","link":"https:\/\/ekiwi-blog.de\/en\/26717\/mklink-access-is-denied\/","title":{"rendered":"mklink Access is denied"},"content":{"rendered":"<p>If you use the <em>mklink<\/em> command under CMD (Command Prompt) or Powershell, it is very likely that you will get the message<\/p>\n<blockquote><p>C:\\&gt;mklink C:\\Users\\danie\\Apple\\MobileSync\\Backup p:\\05_DataBackUp\\iPhone\\<br \/>\nAccess is denied.<\/p><\/blockquote>\n<p>In this case, an attempt was made to bend the <a title=\"iTunes: Find and change backup folder\" href=\"https:\/\/ekiwi-blog.de\/en\/26725\/find-and-change-itunes-backup-location\/\">backup directory under iTunes to another storage location<\/a> via a symlink. Symlinks, so-called symbolic links, are very well suited for this purpose, since they insert a corresponding reference into the system. Whenever a program tries to save files and folders under the specified path, they are saved under the referring path.<\/p>\n<figure id=\"attachment_26710\" aria-describedby=\"caption-attachment-26710\" style=\"width: 650px\" class=\"wp-caption aligncenter\"><img loading=\"lazy\" decoding=\"async\" class=\"size-full wp-image-26710\" src=\"http:\/\/ekiwi-blog.de\/wp-content\/uploads\/2022\/12\/mklink-access-is-denied.jpg\" alt=\"cmd command prompt mklink access is denied\" width=\"650\" height=\"257\" srcset=\"https:\/\/ekiwi-blog.de\/wp-content\/uploads\/2022\/12\/mklink-access-is-denied.jpg 650w, https:\/\/ekiwi-blog.de\/wp-content\/uploads\/2022\/12\/mklink-access-is-denied-300x119.jpg 300w\" sizes=\"auto, (max-width: 650px) 100vw, 650px\" \/><figcaption id=\"caption-attachment-26710\" class=\"wp-caption-text\">CMD <a title=\"Bitlocker and Remote Desktop (RDP) \u2013 Access is denied\" href=\"https:\/\/ekiwi-blog.de\/en\/18625\/bitlocker-and-remote-desktop-rdp-access-is-denied\/\">Access denied<\/a><\/figcaption><\/figure>\n<div id=\"ez-toc-container\" class=\"ez-toc-v2_0_82_2 counter-hierarchy ez-toc-counter ez-toc-grey ez-toc-container-direction\">\n<div class=\"ez-toc-title-container\">\n<p class=\"ez-toc-title\" style=\"cursor:inherit\">Table of content<\/p>\n<span class=\"ez-toc-title-toggle\"><a href=\"#\" class=\"ez-toc-pull-right ez-toc-btn ez-toc-btn-xs ez-toc-btn-default ez-toc-toggle\" aria-label=\"Toggle Table of Content\"><span class=\"ez-toc-js-icon-con\"><span class=\"\"><span class=\"eztoc-hide\" style=\"display:none;\">Toggle<\/span><span class=\"ez-toc-icon-toggle-span\"><svg style=\"fill: #999;color:#999\" xmlns=\"http:\/\/www.w3.org\/2000\/svg\" class=\"list-377408\" width=\"20px\" height=\"20px\" viewBox=\"0 0 24 24\" fill=\"none\"><path d=\"M6 6H4v2h2V6zm14 0H8v2h12V6zM4 11h2v2H4v-2zm16 0H8v2h12v-2zM4 16h2v2H4v-2zm16 0H8v2h12v-2z\" fill=\"currentColor\"><\/path><\/svg><svg style=\"fill: #999;color:#999\" class=\"arrow-unsorted-368013\" xmlns=\"http:\/\/www.w3.org\/2000\/svg\" width=\"10px\" height=\"10px\" viewBox=\"0 0 24 24\" version=\"1.2\" baseProfile=\"tiny\"><path d=\"M18.2 9.3l-6.2-6.3-6.2 6.3c-.2.2-.3.4-.3.7s.1.5.3.7c.2.2.4.3.7.3h11c.3 0 .5-.1.7-.3.2-.2.3-.5.3-.7s-.1-.5-.3-.7zM5.8 14.7l6.2 6.3 6.2-6.3c.2-.2.3-.5.3-.7s-.1-.5-.3-.7c-.2-.2-.4-.3-.7-.3h-11c-.3 0-.5.1-.7.3-.2.2-.3.5-.3.7s.1.5.3.7z\"\/><\/svg><\/span><\/span><\/span><\/a><\/span><\/div>\n<nav><ul class='ez-toc-list ez-toc-list-level-1 ' ><li class='ez-toc-page-1 ez-toc-heading-level-2'><a class=\"ez-toc-link ez-toc-heading-1\" href=\"https:\/\/ekiwi-blog.de\/en\/26717\/mklink-access-is-denied\/#Possible_causes_and_solutions\" >Possible causes and solutions<\/a><ul class='ez-toc-list-level-3' ><li class='ez-toc-heading-level-3'><a class=\"ez-toc-link ez-toc-heading-2\" href=\"https:\/\/ekiwi-blog.de\/en\/26717\/mklink-access-is-denied\/#Run_CMD_as_administrator\" >Run CMD as administrator<\/a><\/li><li class='ez-toc-page-1 ez-toc-heading-level-3'><a class=\"ez-toc-link ez-toc-heading-3\" href=\"https:\/\/ekiwi-blog.de\/en\/26717\/mklink-access-is-denied\/#Spelling\" >Spelling<\/a><\/li><li class='ez-toc-page-1 ez-toc-heading-level-3'><a class=\"ez-toc-link ez-toc-heading-4\" href=\"https:\/\/ekiwi-blog.de\/en\/26717\/mklink-access-is-denied\/#Missing_authorizations\" >Missing authorizations<\/a><\/li><li class='ez-toc-page-1 ez-toc-heading-level-3'><a class=\"ez-toc-link ez-toc-heading-5\" href=\"https:\/\/ekiwi-blog.de\/en\/26717\/mklink-access-is-denied\/#Folder_already_exists\" >Folder already exists<\/a><\/li><\/ul><\/li><\/ul><\/nav><\/div>\n<h2><span class=\"ez-toc-section\" id=\"Possible_causes_and_solutions\"><\/span>Possible causes and solutions<span class=\"ez-toc-section-end\"><\/span><\/h2>\n<p>Unfortunately, <a title=\"Hyper-V UEFI error message: The signed image\u2019s hash is not allowed\" href=\"https:\/\/ekiwi-blog.de\/en\/23430\/hyper-v-uefi-error-message-the-signed-images-hash-is-not-allowed\/\">the error message<\/a> &#8220;Access is denied&#8221; is often displayed, which can have several reasons.<\/p>\n<h3><span class=\"ez-toc-section\" id=\"Run_CMD_as_administrator\"><\/span>Run CMD as administrator<span class=\"ez-toc-section-end\"><\/span><\/h3>\n<p>The first thing to make sure is that you run the CMD prompt or PowerShell as an administrator:<\/p>\n<ol>\n<li>Windows <strong>Start<\/strong> menu enter <strong>CMD<\/strong><\/li>\n<li><strong>Right-click<\/strong> on &#8220;Command Prompt&#8221; and click &#8220;<strong>Run as administrator<\/strong>&#8220;<\/li>\n<\/ol>\n<h3><span class=\"ez-toc-section\" id=\"Spelling\"><\/span>Spelling<span class=\"ez-toc-section-end\"><\/span><\/h3>\n<p>Often the spelling is also suspected or can have a negative effect. There are spellings where the directory paths are put in quotation marks. However, this is not mandatory if the directory path does not contain any spaces.<\/p>\n<h3><span class=\"ez-toc-section\" id=\"Missing_authorizations\"><\/span>Missing authorizations<span class=\"ez-toc-section-end\"><\/span><\/h3>\n<p>Very often, a lack of privileges is cited as a possible cause. But this should not be the reason, because if you run the command prompt as administrator, you have pretty much all privileges. However, it may be worth a try. To view or change the permissions of the corresponding directory:<\/p>\n<ol>\n<li><strong>Right click<\/strong> on the directory and select &#8220;<strong>Properties<\/strong>&#8220;.<\/li>\n<li>Select <strong>&#8220;Security&#8221; tab<\/strong><\/li>\n<\/ol>\n<figure id=\"attachment_26714\" aria-describedby=\"caption-attachment-26714\" style=\"width: 356px\" class=\"wp-caption aligncenter\"><img loading=\"lazy\" decoding=\"async\" class=\"size-full wp-image-26714\" src=\"http:\/\/ekiwi-blog.de\/wp-content\/uploads\/2022\/12\/folder-properties-security.jpg\" alt=\"Screenshot Folder Properties tab Security\" width=\"356\" height=\"475\" srcset=\"https:\/\/ekiwi-blog.de\/wp-content\/uploads\/2022\/12\/folder-properties-security.jpg 356w, https:\/\/ekiwi-blog.de\/wp-content\/uploads\/2022\/12\/folder-properties-security-225x300.jpg 225w\" sizes=\"auto, (max-width: 356px) 100vw, 356px\" \/><figcaption id=\"caption-attachment-26714\" class=\"wp-caption-text\">Select &#8220;Security&#8221; tab<\/figcaption><\/figure>\n<h3><span class=\"ez-toc-section\" id=\"Folder_already_exists\"><\/span>Folder already exists<span class=\"ez-toc-section-end\"><\/span><\/h3>\n<p>However, it is very likely that the folder for which the link is to be created via mklink already exists.\u00a0 Then it cannot be overwritten with the new link. That means you have to delete the directory first. In the example above it was the folder <em>&#8220;Backup&#8221;<\/em> under <em>&#8220;C:\\&#8221;<\/em>. If you <a title=\"Folder in Use \u2013 Can not delete folder in Windows\" href=\"https:\/\/ekiwi-blog.de\/en\/17952\/folder-in-use-can-not-delete-folder-in-windows\/\">delete this folder<\/a>, you can also run mklink.<\/p>\n<figure id=\"attachment_26708\" aria-describedby=\"caption-attachment-26708\" style=\"width: 649px\" class=\"wp-caption aligncenter\"><img loading=\"lazy\" decoding=\"async\" class=\"size-full wp-image-26708\" src=\"http:\/\/ekiwi-blog.de\/wp-content\/uploads\/2022\/12\/mklink-symbolic-link-created.jpg\" alt=\"CMD mklink symbolic link was created\" width=\"649\" height=\"183\" srcset=\"https:\/\/ekiwi-blog.de\/wp-content\/uploads\/2022\/12\/mklink-symbolic-link-created.jpg 649w, https:\/\/ekiwi-blog.de\/wp-content\/uploads\/2022\/12\/mklink-symbolic-link-created-300x85.jpg 300w\" sizes=\"auto, (max-width: 649px) 100vw, 649px\" \/><figcaption id=\"caption-attachment-26708\" class=\"wp-caption-text\">successful created symlink with mklink<\/figcaption><\/figure>","protected":false},"excerpt":{"rendered":"<p>If you use the mklink command under CMD (Command Prompt) or Powershell, it is very likely that you will get<\/p>\n","protected":false},"author":2,"featured_media":13308,"comment_status":"open","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[1555],"tags":[1558],"class_list":["post-26717","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-software-en","tag-windows-en"],"_links":{"self":[{"href":"https:\/\/ekiwi-blog.de\/en\/wp-json\/wp\/v2\/posts\/26717","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/ekiwi-blog.de\/en\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/ekiwi-blog.de\/en\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/ekiwi-blog.de\/en\/wp-json\/wp\/v2\/users\/2"}],"replies":[{"embeddable":true,"href":"https:\/\/ekiwi-blog.de\/en\/wp-json\/wp\/v2\/comments?post=26717"}],"version-history":[{"count":0,"href":"https:\/\/ekiwi-blog.de\/en\/wp-json\/wp\/v2\/posts\/26717\/revisions"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/ekiwi-blog.de\/en\/wp-json\/wp\/v2\/media\/13308"}],"wp:attachment":[{"href":"https:\/\/ekiwi-blog.de\/en\/wp-json\/wp\/v2\/media?parent=26717"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/ekiwi-blog.de\/en\/wp-json\/wp\/v2\/categories?post=26717"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/ekiwi-blog.de\/en\/wp-json\/wp\/v2\/tags?post=26717"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}