How to download Craft CMS logs using SSH and Terminal

A step by step guide on downloading logs from a Craft CMS hosted on Fortrabbit using SSH and Terminal.

Oscar de la Hera Gomez
Written by Oscar de la Hera Gomez
First published on 07/31/2023 at 08:05
Last Updated on 07/31/2023 at 09:35
<p>Two flowers representing Craft CMS and Terminal. Beneath them sits the text "Download Logs on a Hosted Craft CMS."<br /></p>

A step by step guide on downloading logs from a Craft CMS hosted on Fortrabbit using SSH and Terminal.

Subscribe

Step One: SSH into the server

<p>A screenshot of Terminal showing what the terminal looks like after you have successfully accessed a hosted craft cms using SSH on Fortrabbit.</p>

Follow the tutorial below to learn how to SSH into the server.

How to SSH into a hosted Craft CMS

Step Two: Determine the Logs you want to Download

<p>A screenshot of Terminal showing the logs that are available when running the command found below.</p>

Set the current directory to storage/logs and run the ls command to list the logs that are available.

cd storage/logs; ls

Take a note of the the name of the log file that you wish to download.

Step Three: Download the File

<p>A screenshot of Terminal showing how it asks for your password after you attempt to download a file using the command below.</p>

Open a new terminal window and type in a command similar to the one below.

Replace username@host with the username@host that you used to SSH into your server in Step One and path/on/your/computer is the path where you wish the file to be downloaded to.

scp username@host:storage/logs/log.file path/on/your/computer

You will be prompted to enter a password, use the same one that you used to SSH in.

After you enter your password, the terminal will transition to a visual similar to that below which will inform you of the progress made as you download the file.

<p>A screenshot of Terminal showing you what Terminal looks like when a file is being downloaded.</p>

Any Questions?

We are actively looking for feedback on how to improve this resource. Please send us a note to inquiries@delasign.com with any thoughts or feedback you may have.
SubscribeContact UsVisit our BlogView our ServicesView our Work

Partner with us

We would love to get to know you and see how we can help your organization with its goals and needs.
Let's Talk

Stay Informed

Get occasional updates about our company, research, and product launches.
Subscribe