Μηνιαία αρχεία: Μάιος 2021


RIP tux.crystalxp.net 7

Below you will find some images we were able to salvage from https://tux.crystalxp.net/, it was a great repository of Tux creations. Let’s hope it will be restored eventually.

For more images of Tux please visit the following links (we had to split them to multiple pages to avoid having your browser getting stuck):

  1. https://bytefreaks.net/gnulinux/rip-tux-crystalxp-net
  2. https://bytefreaks.net/gnulinux/rip-tux-crystalxp-net-second-part
  3. https://bytefreaks.net/gnulinux/rip-tux-crystalxp-net-third-part
  4. https://bytefreaks.net/gnulinux/rip-tux-crystalxp-net-fourth-part
  5. https://bytefreaks.net/gnulinux/rip-tux-crystalxp-net-fifth-part
  6. https://bytefreaks.net/uncategorized/rip-tux-crystalxp-net-sixth-part
  7. https://bytefreaks.net/uncategorized/rip-tux-crystalxp-net-seventh-part
  8. https://bytefreaks.net/gnulinux/rip-tux-crystalxp-net-eigth-part
  9. https://bytefreaks.net/gnulinux/rip-tux-crystalxp-net-ninth-part
  10. https://bytefreaks.net/gnulinux/rip-tux-crystalxp-net-tenth-part
  11. https://bytefreaks.net/gnulinux/rip-tux-crystalxp-net-eleventh-part
  12. https://bytefreaks.net/gnulinux/rip-tux-crystalxp-net-twelfth-part
  13. https://bytefreaks.net/gnulinux/rip-tux-crystalxp-net-thirdtenth-part
  14. https://bytefreaks.net/gnulinux/rip-tux-crystalxp-net-fourteenth-part
  15. https://bytefreaks.net/gnulinux/rip-tux-crystalxp-net-fifteenth-part
  16. https://bytefreaks.net/gnulinux/rip-tux-crystalxp-net-sixteenth-part
  17. https://bytefreaks.net/gnulinux/rip-tux-crystalxp-net-seventeenth-part
  18. https://bytefreaks.net/gnulinux/rip-tux-crystalxp-net-eighteenth-part
  19. https://bytefreaks.net/gnulinux/rip-tux-crystalxp-net-nineteenth-part
  20. https://bytefreaks.net/gnulinux/rip-tux-crystalxp-net-twentieth-part

License: GNU LGPL


Cut a video based on start and end time using FFmpeg

You probably don’t have a keyframe at the specified second mark if you can’t cut a video at a particular moment.
Non-keyframes need all of the data beginning with the previous keyframe because they encode variations from other frames.

Using an edit list, it is possible to cut at a non-keyframe with the mp4 container without re-encoding.
In other words, if the closest keyframe before 3s is at 0s, the video will be copied starting at 0s, and FFmpeg will use an edit list to tell the player to begin playing 3 seconds in.

If you’re using the latest version of FFmpeg from git master, it’ll use an edit list when you run it with the command you give.
If this does not work for you, it is you are likely using an older version of FFmpeg or that your player does not support edit lists.
Some players can disregard the edit list and play the entire file from beginning to end, regardless of the edit list.

If you want to cut specifically at a non-keyframe and have it play at the desired point on a player that doesn’t support edit lists, or if you want to make sure the cut section isn’t in the output file (for example, if it includes sensitive information), you can do so by re-encoding so that a keyframe is present at the desired start time.
If you don’t mention copy, re-encoding is the norm.
Consider the following scenario:

ffmpeg -i input.mp4 -ss 00:00:07 -t 00:00:18 -async 1 output.mp4
  • The -t option defines a length rather than an end time.
  • The command above will encode 18 seconds of video beginning at 7 seconds.
  • Use -t 8 to start at 7 seconds and end at 15 seconds.
  • If you’re using a recent version of FFmpeg, you can also use -to instead of -t in the above command to make it end at the required time.

psftp.exe: The server’s host key is not cached in the registry. You have no guarantee that the server is the computer you think it is.

Recently, we were debugging a scheduled job running on a Microsoft SQL Server Agent. After starting the SQL Server Management Studio, we saw that the specific task was using psftp.exe to upload some data securely to a remote server. When executing the job manually, it would work as expected. On the other hand, when the job would be executed automatically, it would always fail. After review the error logs, we got the following message:

Executed as user: FSRV\SYSTEM. …s\FTP\remote-server.ppk myuser@remote-server -batch -bc -be -b C:\putty\upload.txtThe server's host key is not cached in the registry. You  have no guarantee that the server is the computer you  think it is.  The server's rsa2 key fingerprint is:  ssh-rsa 2048 39:e4:84:b2:6f:bc:87:04:1f:21:bf:32:83:79:0b:cf  Connection abandoned.  DTSRun:  Loading…   DTSRun:  Executing…   DTSRun OnStart:  DTSStep_DTSExecuteSQLTask_1   DTSRun OnFinish:  DTSStep_DTSExecuteSQLTask_1   DTSRun OnStart:  DTSStep_DTSExecuteSQLTask_3   DTSRun OnFinish:  DTSStep_DTSExecuteSQLTask_3   DTSRun OnStart:  DTSStep_DTSActiveScriptTask_2   DTSRun OnFinish:  DTSStep_DTSActiveScriptTask_2   DTSRun OnStart:  DTSStep_DTSActiveScriptTask_3   DTSRun OnFinish:  DTSStep_DTSActiveScriptTask_3   DTSRun OnStart:  DTSStep_DTSDataPumpTask_1   DTSRun OnProgress:  DTSStep_DTSDataPumpTask_1; 34 Rows have been transformed or copied.; …  Process Exit Code 1.  The step failed.

The problem was with the account executing the scheduled job, which was different than the one that created the job. The second account, the one that was executing the scheduled jobs did not have any knowledge of the ssh-rsa key of the remote server. Because of this lack of information, psftp.exe could not verify that we were indeed trying to connect to the correct server. To fix this issue, we modified the psftp.exe execution command to match the following one:

C:\putty\psftp.exe -i C:\connections\FTP\remote-server.ppk myuser@remote-server -batch -bc -be -b C:\putty\upload.txt -hostkey 39:e4:84:b2:6f:bc:87:04:1f:21:bf:32:83:79:0b:cf

To help any reader that is not familiar with the psftp.exe and powershell (or cmd) we will breakdown the arguments of the above command:

  • C:\putty\psftp.exe : is the exact location of the psftp.exe binary on that server
  • -i C:\connections\FTP\remote-server.ppk : PPK files are PuTTY Private Key Files developed by Putty and they serve as storage for the private keys the program generated. In this case, instead of using a combination of username and password to authenticate, the client was given a private key to use as proof of identity and authenticity.
  • myuser@remote-server : The username and the domain or IP of the remote server.
  • -batch : Disables interactive prompts as no person will be supervising the script.
  • -bc : It displays batch commands in the same way they are run. It is useful for logging and troubleshooting.
  • -be : When running a batch file, this additional option causes psftp.exe to continue processing even if a command fails to complete successfully. An example you might want this to happen is the following: you want to delete a file and don’t care if it is already not present.
  • -b C:\putty\upload.txt : It specifies a file with batch commands. This argument helps users automate tasks by allowing them to set commands in advance.
  • -hostkey 39:e4:84:b2:6f:bc:87:04:1f:21:bf:32:83:79:0b:cf : Here, we copied the rsa-ssh key of the server that was displayed on the error and we explicitly defined it to let psftp.exe that it is trying to connect to the correct server. If you are not sure if the value you get at the errors is indeed the correct value, consult your system administrator.