{"id":23663327,"url":"https://github.com/jorbush/pi-shared-file-system-hard-drive","last_synced_at":"2026-01-25T13:01:11.323Z","repository":{"id":269585987,"uuid":"907838710","full_name":"jorbush/pi-shared-file-system-hard-drive","owner":"jorbush","description":"setting up a shared file system on a Raspberry Pi with external hard drives","archived":false,"fork":false,"pushed_at":"2024-12-24T15:32:37.000Z","size":3,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-05-20T19:20:17.877Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":null,"has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/jorbush.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2024-12-24T14:13:39.000Z","updated_at":"2024-12-24T15:32:40.000Z","dependencies_parsed_at":null,"dependency_job_id":"7cc464b9-55ef-4367-b204-c5b818879717","html_url":"https://github.com/jorbush/pi-shared-file-system-hard-drive","commit_stats":null,"previous_names":["jorbush/pi-shared-file-system-hard-drive"],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/jorbush/pi-shared-file-system-hard-drive","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jorbush%2Fpi-shared-file-system-hard-drive","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jorbush%2Fpi-shared-file-system-hard-drive/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jorbush%2Fpi-shared-file-system-hard-drive/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jorbush%2Fpi-shared-file-system-hard-drive/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/jorbush","download_url":"https://codeload.github.com/jorbush/pi-shared-file-system-hard-drive/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jorbush%2Fpi-shared-file-system-hard-drive/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":28753411,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-01-25T10:25:12.305Z","status":"ssl_error","status_checked_at":"2026-01-25T10:25:11.933Z","response_time":113,"last_error":"SSL_connect returned=1 errno=0 peeraddr=140.82.121.5:443 state=error: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2024-12-29T05:20:20.976Z","updated_at":"2026-01-25T13:01:11.311Z","avatar_url":"https://github.com/jorbush.png","language":null,"funding_links":[],"categories":[],"sub_categories":[],"readme":"# Set up a shared file system on a Raspberry Pi with external hard drives\n\n## Format drive\n\nSee disks:\n```sh\nlsblk -f\n```\nYou will see something like this:\n```\nraspberry@raspberrypi:~ $ lsblk -f\nNAME        FSTYPE   FSVER LABEL                     UUID                                 FSAVAIL FSUSE% MOUNTPOINT\nloop0       squashfs 4.0                                                                        0   100% /snap/btop/784\nloop1       squashfs 4.0                                                                        0   100% /snap/btop/794\nloop2       squashfs 4.0                                                                        0   100% /snap/core/17202\nloop3       squashfs 4.0                                                                        0   100% /snap/core/16932\nloop4       squashfs 4.0                                                                        0   100% /snap/core22/1721\nloop5       squashfs 4.0                                                                        0   100% /snap/core22/1437\nsda\n├─sda1      ntfs           Reservado para el sistema 04361FBB361FACA4                       73.7M    26% /media/raspberry/Reservado para el sistema\n└─sda2      ntfs                                     4CF02256F0224714                      223.5G    25% /media/raspberry/4CF02256F0224714\nsdb\n└─sdb1      vfat     FAT32                           CD41-F882                                29G     0% /media/raspberry/CD41-F882\nsdc         ext4     1.0                             120134c2-fea4-4ae4-9820-7a5698bdb955  555.9G     0% /mnt/drive1\nsdd\n├─sdd1      vfat     FAT32 PQSERVICE                 A20A-9608\n├─sdd2      ntfs           ACER                      A22AA8492AA81BF3                       67.1G    40% /media/raspberry/ACER\n└─sdd3      ntfs           DATA                      FE923C7D923C3D09                      111.5G     0% /media/raspberry/DATA\nmmcblk0\n├─mmcblk0p1 vfat     FAT32 boot                      17B6-FC00                             200.8M    20% /boot\n└─mmcblk0p2 ext4     1.0   rootfs                    b101bb80-3338-4b94-a775-b3844f8f2aa8   49.4G    11% /\n```\nFormat the drive the you want:\n```sh\nsudo mkfs.ext4 /dev/sdd\n```\n\u003e [!NOTE]\n\u003e Replace `sdd` for the drive that you want\n\n## Mount the drive\n\nCreate your mount directory:\n```sh\nsudo mkdir /mnt/drive2\n```\nMount:\n```sh\nsudo mount /dev/sdd /mnt/drive2\n```\nAdd it to `/etc/fstab` (you can use `nano` too):\n```sh\nsudo vi /etc/fstab\n```\nAnd add the following line with the uuid of your drive (you can see it using `lsblk -f` that we have used at the beginning)\n```\n/dev/disk/by-uuid/be89d5f1-815c-4f88-b691-48662ecf1884 /mnt/drive2 auto nosuid,nodev,nofail,x-gvfs-show 0 0\n```\nUpdate permissions:\n```sh\nsudo chown -R raspberry:raspberry /mnt\n```\n\n## Enable shared file system\n\nInstall samba:\n```sh\nsudo apt-get install samba\n```\nWrite a new entry in the config:\n```\nsudo vi /etc/samba/smb.conf\n```\nWith this content at the end:\n```\n[drive2]\n  comment = My shared folder 2\n  path = /mnt/drive2\n  browseable = yes\n  read only = no\n  guest ok = no\n  create mask = 0755\n  directory mask = 0755\n  valid users = raspberry\n```\nRestart samba:\n```sh\nsudo systemctl restart smbd\n```\nAdd user for samba:\n```sh\nsudo smbpasswd -a raspberry\n```\nIn other computer you can add the device in `Network`:\n```sh\nsmb://\u003cIP-Raspberry\u003e/drive1\n```\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fjorbush%2Fpi-shared-file-system-hard-drive","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fjorbush%2Fpi-shared-file-system-hard-drive","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fjorbush%2Fpi-shared-file-system-hard-drive/lists"}