1. OCAU Merchandise is available! Check out our 20th Anniversary Mugs, Classic Logo Shirts and much more! Discussion in this thread.
    Dismiss Notice

RetroNAS

Discussion in 'Retro & Arcade' started by elvis, Nov 27, 2021.

  1. OP
    OP
    elvis

    elvis OCAU's most famous and arrogant know-it-all

    Joined:
    Jun 27, 2001
    Messages:
    46,810
    Location:
    Brisbane
    Did you rename the ps3 folder too?

    Hrm... though it's whinging about the roms/ path. That's weird. I re-ran on a clean install here and it's working OK.

    Let me see if I can reconstruct some things and break it.
     
    Last edited: Feb 2, 2022
  2. greencamel65

    greencamel65 Member

    Joined:
    Jan 17, 2003
    Messages:
    756
    Location:
    Asgard
    I went one step further, i deleted the ps3 folder completly as i didn't have anything noteworthy in it.

    Code:
    pi@retronas:/data/retronas$ ls -lh
    total 16K
    drwxr-xr-x 1 pi pi   10 Jan 11 15:35 3ds
    drwxr-xr-x 6 pi pi  16K Jan  1  1970 dos
    drwxrwxr-x 1 pi pi 2.9K Jan 15 01:09 gog
    drwxrwxr-x 1 pi pi 1.1K Feb  1 20:48 mister
    drwxrwxr-x 1 pi pi   26 Feb  1 21:13 ps2
    drwxrwxr-x 1 pi pi   26 Jan 29 21:29 ps2.old
    drwxrwxr-x 1 pi pi  238 Feb  1 23:22 roms
    drwxrwxr-x 1 pi pi  238 Feb  1 20:47 roms.old
    drwxrwxr-x 1 pi pi  238 Jan 31 11:55 Software
    drwxrwxr-x 1 pi pi   10 Feb  1 22:06 xbox360
    drwxrwxr-x 1 pi pi  158 Jan 11 21:19 xbox360.old
     
  3. OP
    OP
    elvis

    elvis OCAU's most famous and arrogant know-it-all

    Joined:
    Jun 27, 2001
    Messages:
    46,810
    Location:
    Brisbane
    Hrm I wonder what the heck is going on.

    I can get the same error if the ps3 folder exists with directories. But I can't if I clean it out. I'm not sure how to reproduce the setup to get the same error.

    All your paths and folders look correct. Tricky one. Let me sleep on it.
     
  4. greencamel65

    greencamel65 Member

    Joined:
    Jan 17, 2003
    Messages:
    756
    Location:
    Asgard
    Cheers,

    The username might be a bit deceptive, its running as a vm, with a couple of drives passed through setup as a btrfs volume.
     
  5. OP
    OP
    elvis

    elvis OCAU's most famous and arrogant know-it-all

    Joined:
    Jun 27, 2001
    Messages:
    46,810
    Location:
    Brisbane
    Can you do me a favour and try the OpenPS2Loader and/or MiSTer installers too? Both of those use the new symlink structure too, and might be worth a test to see what happens there.

    Both are just smb shares, so they're easy enough to delete after if you don't need them.
     
  6. greencamel65

    greencamel65 Member

    Joined:
    Jan 17, 2003
    Messages:
    756
    Location:
    Asgard
    Additional troubleshooting

    * commented out the btrfs volume in my fstab, rebooted - attempt to rule out a file system error
    * removed the retronas folder & recreated
    * ran the MiSTer installer - installed without fault
    * ran the OpenPS2Loader installer - installed without fault
    * ran the PS3netsrv instasller - faulted again.

    Happy to blow away the install and try again if you think this is an isolated fault and in the too hard, not enough time basket.
     
  7. Pierre32

    Pierre32 Member

    Joined:
    Oct 13, 2019
    Messages:
    1,910
    Location:
    Sydney
    Getting MAME onto the DOS machine (the third emulator on there now, with MSX and NES) has pushed me to get my ROM storage sorted out on the NAS. Although I don't have any consoles in the picture right now, I wanted the RetroNAS ROM structure, so I figured ps3netsrv was the topical one to install. I'm failing at the same point:

    Code:
    TASK [ps3netsrv - build layout] *******************************************************************************************************************************************
    failed: [localhost] (item={'src': '../../roms/sony/playstation3/games', 'dest': 'GAMES'}) => {"ansible_loop_var": "item", "changed": false, "item": {"dest": "GAMES", "src": "../../roms/sony/playstation3/games"}, "msg": "src file does not exist, use \"force=yes\" if you really want to create the link: /media/pi/ntfs/ps3/ps3netsrv/../../roms/sony/playstation3/games", "path": "/media/pi/ntfs/ps3/ps3netsrv/GAMES", "src": "../../roms/sony/playstation3/games"}
    failed: [localhost] (item={'src': '../../roms/sony/playstation3/iso', 'dest': 'PS3ISO'}) => {"ansible_loop_var": "item", "changed": false, "item": {"dest": "PS3ISO", "src": "../../roms/sony/playstation3/iso"}, "msg": "src file does not exist, use \"force=yes\" if you really want to create the link: /media/pi/ntfs/ps3/ps3netsrv/../../roms/sony/playstation3/iso", "path": "/media/pi/ntfs/ps3/ps3netsrv/PS3ISO", "src": "../../roms/sony/playstation3/iso"}
    failed: [localhost] (item={'src': '../../roms/sony/playstation2/dvd', 'dest': 'PS2ISO'}) => {"ansible_loop_var": "item", "changed": false, "item": {"dest": "PS2ISO", "src": "../../roms/sony/playstation2/dvd"}, "msg": "src file does not exist, use \"force=yes\" if you really want to create the link: /media/pi/ntfs/ps3/ps3netsrv/../../roms/sony/playstation2/dvd", "path": "/media/pi/ntfs/ps3/ps3netsrv/PS2ISO", "src": "../../roms/sony/playstation2/dvd"}
    failed: [localhost] (item={'src': '../../roms/sony/playstation1/iso', 'dest': 'PSXISO'}) => {"ansible_loop_var": "item", "changed": false, "item": {"dest": "PSXISO", "src": "../../roms/sony/playstation1/iso"}, "msg": "src file does not exist, use \"force=yes\" if you really want to create the link: /media/pi/ntfs/ps3/ps3netsrv/../../roms/sony/playstation1/iso", "path": "/media/pi/ntfs/ps3/ps3netsrv/PSXISO", "src": "../../roms/sony/playstation1/iso"}
    failed: [localhost] (item={'src': '../../roms/sony/playstationportable/iso', 'dest': 'PSPISO'}) => {"ansible_loop_var": "item", "changed": false, "item": {"dest": "PSPISO", "src": "../../roms/sony/playstationportable/iso"}, "msg": "src file does not exist, use \"force=yes\" if you really want to create the link: /media/pi/ntfs/ps3/ps3netsrv/../../roms/sony/playstationportable/iso", "path": "/media/pi/ntfs/ps3/ps3netsrv/PSPISO", "src": "../../roms/sony/playstationportable/iso"}
    failed: [localhost] (item={'src': '../../roms/videos/bdiso', 'dest': 'BDISO'}) => {"ansible_loop_var": "item", "changed": false, "item": {"dest": "BDISO", "src": "../../roms/videos/bdiso"}, "msg": "src file does not exist, use \"force=yes\" if you really want to create the link: /media/pi/ntfs/ps3/ps3netsrv/../../roms/videos/bdiso", "path": "/media/pi/ntfs/ps3/ps3netsrv/BDISO", "src": "../../roms/videos/bdiso"}
    failed: [localhost] (item={'src': '../../roms/videos/dvdiso', 'dest': 'DVDISO'}) => {"ansible_loop_var": "item", "changed": false, "item": {"dest": "DVDISO", "src": "../../roms/videos/dvdiso"}, "msg": "src file does not exist, use \"force=yes\" if you really want to create the link: /media/pi/ntfs/ps3/ps3netsrv/../../roms/videos/dvdiso", "path": "/media/pi/ntfs/ps3/ps3netsrv/DVDISO", "src": "../../roms/videos/dvdiso"}
    
    PLAY RECAP ****************************************************************************************************************************************************************
    localhost                  : ok=3    changed=1    unreachable=0    failed=1    skipped=0    rescued=0    ignored=0
    
    Also, should I be seeing a ps3 folder here?

    upload_2022-2-2_8-51-18.png

    After this I tried OpenPS2Loader which installed without issue, and got my \ps2 folder.

    I have my ROM directory structure though. Thoughts on this & DOS are for a separate post.
     
  8. OP
    OP
    elvis

    elvis OCAU's most famous and arrogant know-it-all

    Joined:
    Jun 27, 2001
    Messages:
    46,810
    Location:
    Brisbane
    Ok if you're both blowing up there I must have something wrong. I'll clean out my structure and start from scratch.

    Can you share the output of

    find /<retronaspath>/ps3

    And likewise if you cd /<retronaspath>/ps3/ps3netsrv and

    ls -lad ../../roms/sony/playstation3/iso

    What does that say?

    Also, just checking that these paths are on a non-FAT filesystem. NTFS can do symlinks, but FAT can't.
     
    Last edited: Feb 2, 2022
  9. Pierre32

    Pierre32 Member

    Joined:
    Oct 13, 2019
    Messages:
    1,910
    Location:
    Sydney
    Code:
    root@retronas:~# find /media/pi/ntfs/ps3
    find: '/media/pi/ntfs/ps3': No such file or directory
    
    root@retronas:~# cd /media/pi/ntfs/ps3/ps3netsrv
    bash: cd: /media/pi/ntfs/ps3/ps3netsrv: No such file or directory
    
    root@retronas:~# ls -lad /media/pi/ntfs/roms/sony/playstation3/iso
    drwxrwxrwx 1 root root 0 Feb  2 08:30 /media/pi/ntfs/roms/sony/playstation3/iso
    
    [edit] Yep, this is the NTFS volume. As a side note, I'm seeing the symlink magic in action as I add ROMs (eg. megadrive/genesis).
     
  10. greencamel65

    greencamel65 Member

    Joined:
    Jan 17, 2003
    Messages:
    756
    Location:
    Asgard
    Code:
    pi@retronas:/data/retronas$ find /data/retronas/ps3
    find: ‘/data/retronas/ps3’: No such file or directory
    pi@retronas:/data/retronas$ cd /data/retronas/ps3/ps3netsrv
    -bash: cd: /data/retronas/ps3/ps3netsrv: No such file or directory
    pi@retronas:/data/retronas$ ls -lad /data/retronas/roms/sony/playstation3/iso/
    drwxrwxr-x 1 pi pi 0 Feb  1 20:47 /data/retronas/roms/sony/playstation3/iso/
    btrfs volume, and like Pierre32 i'm seeing the symlink magic as i add roms.
     
  11. OP
    OP
    elvis

    elvis OCAU's most famous and arrogant know-it-all

    Joined:
    Jun 27, 2001
    Messages:
    46,810
    Location:
    Brisbane
    Yes, sleep was indeed the missing component.

    I did a stupid thing, replaced PS3 stuff with symlink stuff, but forgot to build the directory above the symlinks. What a goose.

    Fix committed now. Please retest, and many thanks for your testing, help and patience!
     
    MUTMAN and Pierre32 like this.
  12. greencamel65

    greencamel65 Member

    Joined:
    Jan 17, 2003
    Messages:
    756
    Location:
    Asgard
    Cheers, installs without fault now. (although testing functionality on a ps3 will have to wait until after work hours)

    Keep up the good work!

    edit: as a side note, has the 360 been updated to use the roms folder?
     
    Last edited: Feb 2, 2022
    elvis likes this.
  13. Pierre32

    Pierre32 Member

    Joined:
    Oct 13, 2019
    Messages:
    1,910
    Location:
    Sydney
    Yep, sorted! :thumbup:
     
    elvis likes this.
  14. OP
    OP
    elvis

    elvis OCAU's most famous and arrogant know-it-all

    Joined:
    Jun 27, 2001
    Messages:
    46,810
    Location:
    Brisbane
    Not yet no, apologies. I haven't even tested that for myself yet.

    Any tips? I was thinking under the generic roms/microsoft/xbox360 making an "iso" and "games", and using "games" as the Xbox360 entry point. From what I can tell, it only supports extracted gamedirs, and not ISOs, right?
     
  15. greencamel65

    greencamel65 Member

    Joined:
    Jan 17, 2003
    Messages:
    756
    Location:
    Asgard
    No need for apologies - Your doing all the hard work, i'm just coming along for the ride.

    I think that that would work great, and as far as i'm aware it only supports extracted gamedirs - at least in the way i've configured my xbox.
     
  16. Pierre32

    Pierre32 Member

    Joined:
    Oct 13, 2019
    Messages:
    1,910
    Location:
    Sydney
    The thoughts.

    Obviously my new, RetroNAS-established /roms dir on the NTFS volume is inaccessible to DOS, which only sees the FAT volume. (Even if it could see it, NTFS would be a showstopper, and there also ain't many rom sets with 8.3 filenames). I know I have some fancier mounting options to learn about, but I'm still not confident there will be a pathway to DOS reading this structure.

    My assumption is that roms for use in DOS will need to be managed separately in their FAT volume. I don't think this is a drama. The number of systems you would be emulating under DOS is relatively small, and the userbase for this is probably tiny too.

    Here's a little daydream though: A tool that establishes a separate /roms in your dedicated DOS share, and does a one-time copy of selected systems with 8.3 filename conversion in the process. It wouldn't be symlinked, but there could be some kind of sync function.
     
  17. Grant

    Grant Member

    Joined:
    Jan 23, 2002
    Messages:
    1,907
    Location:
    Wollongong
    Management of various RetroNAS shares from a larger environment (say a real NAS that you treat as secure) is something where you could go way deep with SyncThing and partial mirroring.
     
  18. OP
    OP
    elvis

    elvis OCAU's most famous and arrogant know-it-all

    Joined:
    Jun 27, 2001
    Messages:
    46,810
    Location:
    Brisbane
    I'm not sure if I could do it within RetroNAS itself, but maybe with some best-practice stuff and guides I can show a way to do it.

    The goal was to show people how to mount a FAT volume under /dos using any one of a separate partition, a logical volume, or a loop mounted file. All can be managed in Cockpit.

    From there, a robocopy script simply with the "/fat" flag (that will force files into 8.3) could be run over SMB (say from a Win10 host) and that will sync anything you like into the "dos" folder. Whether it's your entire "roms" dir, or anything in a lower level directory. Maybe that's something I can write and offer as a template?

    Not sure if there's a Linux equivalent that can intelligently map long names to 8.3.

    [edit]

    Or this?
    https://robocopy-gui.software.informer.com/
     
    Last edited: Feb 2, 2022
  19. Pierre32

    Pierre32 Member

    Joined:
    Oct 13, 2019
    Messages:
    1,910
    Location:
    Sydney
    I'll be happy to investigate the copy/rename idea further since it's probably a task I can handle, and one less added to your list. I've already been looking into renaming methods with either CMD or Bash. What to sync is another investigation, so homework into available DOS emulators is required. And a modified rom folder structure to suit the environment.

    Leave it with me, and hopefully I can come back with the bones of something at least.

    It would be pretty easy to throw together something for myself in Win10, but I think it would be way cooler to do it from the RetroNAS terminal. Or even better, from the DOS rig over Telnet.
     
    elvis likes this.
  20. Pierre32

    Pierre32 Member

    Joined:
    Oct 13, 2019
    Messages:
    1,910
    Location:
    Sydney
    I have a working bash script for renaming files to 8.3 format. I can't write this stuff; I borrow from wherever I can, then get smarter people to help me make it work. This is probably imperfect, and it's definitely dangerous if run in the wrong location.

    Code:
    #!/bin/bash
    
    # remove spaces and special characters
    
    for file in *; do mv "$file" $(echo "$file" | sed -e 's/[^A-Za-z0-9._]//g'); done
    
    # shorten filenames to 8 chars, increment duplicates
    
    length=8
    for file in *; do
        newname=$file
        extension=${file: -4}
        for (( num=1; ; num++ )); do
            (( sublen = length - ${#num} ))
            printf -v newname '%.*s%d%s' "$sublen" "$file" "$num" "$extension"
            [[ ! -f $newname ]] && break
        done
        mv -- "$file" "$newname"
    done
    
    Filenames before & after:

    1943 - The Battle of Midway (U).zip
    Bionic Commando (U) [!].zip
    Duck Tales.nes
    Duck Tales 2.nes
    Mega Man (U).nes
    Mega Man 2 (U) [!].nes

    1943The1.zip
    BionicC1.zip
    DuckTal1.nes
    DuckTal2.nes
    MegaMan1.nes
    MegaMan2.nes

    The original script was hardcoded to process .jpgs only, and incremented the numbering in one long sequence (so in the above output, the trailing numbers would count up to 6). This version will pick up any filetype, and will reset the count for each new pattern. A side effect of this is that all names will have a 1 at the end by default.

    The numbers can also be misleading depending on what's in your folder. If you have Super Mario All-Stars, Super Mario Kart, & Super Mario World 2, they're going to come out as SuperMa1, SuperMa2, & SuperMa3. That would take some pretty wild smarts to finesse - which is not happening. Taking a look at directory structures next.
     
    andrewbt, MUTMAN and elvis like this.

Share This Page

Advertisement: