if you want to access the Pi using SSH,in the first place you need to get your SSH server enables using Raspi-config.
after that you need to get your RaspberryPI IP . you can easily get that by typing
ip addr | grep ‘inet .* eth0’
lets say that you got this result from the command above :
inet 192.168.2.109/24 brd 192.168.2.255 scope global eth0
now you can start SSH from the command line, passing it the Pi user’s IP address. you will be asked to enter user’s password
lets start off with getting to know what is Unix time stamp.
UNIX time stamp is a way to track time in seconds, the tracking start from 01-01-1970.
in ServiceNow,sometimes we are in need for this kind of format especially in integration tasks . the function below would make it easy to convert glide date to UNIX time stamp 🙂
// Import Java Date Class
var Date = Packages.java.util.Date;
//get glide date object
var gdt =passdate.getGlideObject();
// create instance from date object . pass date as milliseconds . getNumericValue() would do the job
var date = new Date(gdt.getNumericValue());
// getTime converts date to unix time stamp
var diff = date.getTime();
// return unix time stamp
as i start this article, i have a confusion to say . i really hate working with date:).however,if you are dealing a lot with custom integration you probably notice that working with date in ServiceNow is more a complex.
in some cases, like for example sending date in SOAP Message, you need to follow ISO-8601 standard . The example below,shows how to convert GlideDate to ISO 8601 with two different format
Continue reading →