Open DevShivmohan opened 2 years ago
String[] pp = new String[]{"cmd.exe", "/c", "mysqldump --host=<host_name> --user <user_name> --password=<password> --opt <database_name> > <backup_file_name_with_sql_extension>"};
Runtime.getRuntime.exec(pp);
String[] pp = new String[]{"sh", "-c", "mysqldump --host=<host_name> --user <user_name> --password=<password> --opt <database_name> > <backup_file_name_with_sql_extension>"};
Runtime.getRuntime.exec(pp);
Sending file through API via curl mode [for Windows and Linux both]
curl -X POST "http://139.59.56.154:8090/trf/security/send/file/data" -H "accept: */*" -H "Content-Type: multipart/form-data" -F "file=@Shiv.jpg;type=image/jpeg"
OR
curl -X POST "http://139.59.56.154:8090/trf/security/send/file/data" -H "accept: */*" -H "Content-Type: multipart/form-data" -F "file=@Shiv.jpg;"
Shiv.jpg file inside the current directory