- Change your database RDS instance security group to allow your machine to access it.
- Add your ip to the security group to acces the instance via Postgres.
- Make a copy of the database using pg_dump
$ pg_dump -h <public dns> -U <my username> -f <name of dump file .sql> <name of my database>
- you will be asked for postgressql password.
- a dump file(.sql) will be created
- Restore that dump file to your local database.
- but you might need to drop the database and create it first
$ psql -U <postgresql username> -d <database name> -f <dump file that you want to restore>
- the database is restored
psql -U postgres
Some interesting flags (to see all, use
--help depending on your psql version):
-E: will describe the underlaying queries of the
\commands (cool for learning!)
-l: psql will list all databases and then exit (useful if the user you connect with doesn't has a default database, like at AWS RDS)
|ssh-keygen -t rsa -b 4096 -N '' -C "firstname.lastname@example.org" -f ~/.ssh/id_rsa|
|ssh-keygen -t rsa -b 4096 -N '' -C "email@example.com" -f ~/.ssh/github_rsa|
|ssh-keygen -t rsa -b 4096 -N '' -C "firstname.lastname@example.org" -f ~/.ssh/mozilla_rsa|
Converting Audio into Different Formats / Sample Rates
Minimal example: transcode from MP3 to WMA:
ffmpeg -i input.mp3 output.wma
You can get the list of supported formats with:
Convert WAV to MP3, mix down to mono (use 1 audio channel), set bit rate to 64 kbps and sample rate to 22050 Hz:
|Copyright 2012 Viktor Klang|
|Licensed under the Apache License, Version 2.0 (the "License");|
|you may not use this file except in compliance with the License.|
|You may obtain a copy of the License at|
|Unless required by applicable law or agreed to in writing, software|