Announcement

Collapse
No announcement yet.

ls -l

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

    ls -l

    New to linux.

    And the only thing I want to do is make a PI on the rpi remote.

    SSH'd into the rpi.

    Trying to find the file I use "ls -l"

    but this will tell that the system password is changed. How can I see directories and ultimately find the PI file?
    Click image for larger version

Name:	ls-l.PNG
Views:	72
Size:	10.3 KB
ID:	1287356
    Thanks in advance,

    John

    #2
    If you are using a Windows system to access your rPi, I would recommend using WinSCP to access it as it provides a file browser type interface. Just Google it to find the download for it.
    HS 4.2.8.0: 2134 Devices 1252 Events
    Z-Wave 3.0.10.0: 133 Nodes on one Z-Net

    Comment


      #3
      thnx

      Comment


        #4
        Originally posted by sparkman View Post
        If you are using a Windows system to access your rPi, I would recommend using WinSCP to access it as it provides a file browser type interface. Just Google it to find the download for it.
        Thnx for the tip.

        But how can I edit files owned by root.

        The homeseer account does not work and the rpi account also did not work.

        ---
        John

        Comment


          #5
          For directories, I use the following command: ls -la |grep drw. If you know the root password, you can use su command. i.e. su - . Or just su. The difference is that su - will invoke .login or .profile (depending on the shell) which will default you to the root directory along with any profile specific environmental configurations. If you're deep in some directory that has a file owned by root and all you want to do is edit it, you just need to invoke the su command alone. Not overly experienced with Linux, there is a sudo command also gives you god powers.
          HS3PRO 3.0.0.500 as a Fire Daemon service, Windows 2016 Server Std Intel Core i5 PC HTPC Slim SFF 4GB, 120GB SSD drive, WLG800, RFXCom, TI103,NetCam, UltraNetcam3, BLBackup, CurrentCost 3P Rain8Net, MCsSprinker, HSTouch, Ademco Security plugin/AD2USB, JowiHue, various Oregon Scientific temp/humidity sensors, Z-Net, Zsmoke, Aeron Labs micro switches, Amazon Echo Dots, WS+, WD+ ... on and on.

          Comment


            #6
            Your "ls -l" is displaying the file in your current directory. There is one non-hidden file called "system_password_changed" that was last changed on Feb 23 2019 at 11:15. It is owned by the root user id and the root group id and is read writable by root user, read only by the root group and read only by all other ID's on your pi.

            Try "ls -la" and you should see more files.

            If you know the name of the file you are looking for, you can execute "find / -type f | grep -i filename".

            You will then need to "cd" to that directory.

            Edit root files using "sudo vi filename". You may be prompted for your password.
            Len


            HomeSeer Version: HS3 Pro Edition 3.0.0.435
            Linux version: Linux homeseer Ubuntu 16.04 x86_64
            Number of Devices: 633
            Number of Events: 773

            Enabled Plug-Ins
            2.0.54.0: BLBackup
            2.0.40.0: BLLAN
            3.0.0.48: EasyTrigger
            30.0.0.36: RFXCOM
            3.0.6.2: SDJ-Health
            3.0.0.87: weatherXML
            3.0.1.190: Z-Wave

            Comment


              #7
              Originally posted by John245 View Post

              Thnx for the tip.

              But how can I edit files owned by root.

              The homeseer account does not work and the rpi account also did not work.

              ---
              John
              Hi John, what I typically do is go to the file properties, change the file permissions, modify the file and then change the file permissions back to what they were. There may be a more elegant way to do so through the interface, but I’ve never looked.

              Cheers
              Al
              HS 4.2.8.0: 2134 Devices 1252 Events
              Z-Wave 3.0.10.0: 133 Nodes on one Z-Net

              Comment

              Working...
              X