Showing posts with label linux tips & Tricks. Show all posts
Showing posts with label linux tips & Tricks. Show all posts

Tuesday, 15 August 2023

A Guide to Installing and Configuring SSH Tunneling | Windows

Introduction:

Secure communication and data protection are paramount in today's digital landscape. One effective way to ensure this is through the use of SSH tunneling. In this guide, we'll walk you through the process of installing, setting up, and utilizing SSH tunneling on a Windows operating system. This technique will provide you with a secure and encrypted channel for your data transmission needs.

Step 1: Install OpenSSH as a Windows Optional Feature
  1. Begin by installing OpenSSH as an optional feature on your Windows machine.
  2. Windows will automatically create a new firewall rule to permit inbound SSH access over port 22.
Note that, if you manually download and install OpenSSH, you'll need to create an inbound rule to allow SSH port access.

Step 2: Start and Enable the SSH Service

1. Open PowerShell as an administrator
2. Start the SSH service using the following command 
Start-Service ssh

Tuesday, 4 July 2023

How to Download Videos Shared on Microsoft SharePoint and 365 | Microsoft

Is it possible to download a video shared over Microsoft SharePoint or 365 when we can watch it but are unable to download it?

Introduction:

Have you ever encountered a situation where you're able to watch a video shared on Microsoft SharePoint or 365, but you can't seem to find a way to download it? In this guide, we'll walk you through a simple solution that empowers you to download these videos using the versatile media converter, ffmpeg.

Solution: Using FFmpeg Video Converter

FFmpeg is a powerful and universal media converter that can handle a wide range of media tasks, including converting and transcoding videos. Follow these steps to download videos that you can watch but can't download directly from Microsoft SharePoint or 365:

ffmpeg is a universal media converter. It can read a wide variety of inputs - including live grabbing/recording devices - filter, and transcode them into a plethora of output formats.

Monday, 16 October 2017

Anonymize or Replace text within a File using SED | Linux

Stream Editor aka 'sed' is a *nix utility to transform and parse text.

for example.
if a file testing.txt contains some text like ' helloworld.zip ',  it will be replace with any text or we can use $RANDOM function also.
sed s/hello.*zip/"hello://$RANDOM.zip"/g testing.txt
the final result will be like this:
hello12345.zip (any random number)
/g means all occurrence of this text


Friday, 13 October 2017

Find and Delete All Files Older than 10 Days using mtime | Linux

#to file files older than 10 days:
find /home/folder/ -mtime +10;

#now append it with -exec switch +  rm {} loop to delete all found files:
find /home/folder/ -mtime +10 -exec rm {} \;

----------------------
#and to find only in specific directory ignore sub directories

find /home/folder/ -maxdepth 1 -mtime +10

Wednesday, 9 August 2017

What is inode in Linux and IF You are Out of It (solution) | Linux

inode is basically a count of total number of files in directories of a user account in *nix systems.

similar to a unique identification of individuals in a country.

inode is data structure , it contains:
size,
user id,
group id
device id,
mode and access
protection
timestamps
links
points
etc.
except file name, and contents.