Fsck.ext3: Unable to resolve UUID
If you are getting the FSCK error fsck.ext3: Unable to resolve ‘UUID=”0415c1ac-8f7a-49e3-9638-bbab4ceefe9b”‘ on system booting, then you can try following steps to resolve that.
1. Use following command to get the UUID of current partitions.
blkid
2. Open the /etc/fstab file and check the UUID in the fstab and the result of blkid are same.
$ sudo blkid |grep /dev/sda
/dev/sda1: TYPE=”swap” UUID=”0415c1ac-8f7a-49e3-9638-bbab4ceefe9b”
/dev/sda2: LABEL=”Dreamlinux” UUID=”5845b99a-14e0-4bd5-b17a-05a8085b16f3″ TYPE=”ext3″
3. Edit the /etc/fstab and change the UUID to that got from the blkid
That will solve the issue.
Find text in a large number of files
If you need to find a string in a file, you would typically use:
grep -H “string” file-name.ext
However, grep doesn’t handle a large number of files well. If you specify grep “string” * or even grep “string” `find ./`you may find yourself facing this error:
bash: /bin/grep: Argument list too long
Simple bash script to do the searching.
In this sample, We will be looking for a string “welcome” in a directory named “./Document/”:
for i in `find ./Document/`; do grep -H “welcome” $i; done
This uses the find command to do the searching. It actually returns a list of filenames, which we can then grep one-by-one. The -H option tells grep to let us know the filename it found the string in so we can go right into that file to find the location of it.
How do I reset my root password on Debian Server Using GRUB ?
Reboot your Server/Desktop.
1)Press Escape to see your boot menu while booting your server.
2)Choose the kernel you want to boot.
3)Press “e” for edit.
4)Type in the following line after a space on the kernel line.
5)Press enter key and then press “b” to boot that kernel, this will take you into single user mode+
6)Now Mount your Server in Read-Write mode using mount command
7)Reset your root password.
Do I need MX records for my domain?
Technically, a domain does not require MX records to receive email. By default, a sending mail server should attempt to deliver mail to the host itself if no MX record is present. For example, if a sending server is trying to deliver mail to user@example.com, and example.com has no MX records, it will try connecting to any mail server at example.com itself.
However, it is highly recommended to create MX records for your domain, even if they seem redundant or unnecessary; in the above example, example.com should still have at least one MX record set to domain.com itself to help ensure delivery, like so:
example.com 43200 MX 10 example.com
Some non-RFC-compliant servers will fail to deliver email for domains that lack MX records
How to redirect port using IPTABLES
You can redirect the port in IPTABLES using the prerouting parameter.
Following is the command you can use to redirect the traffic of the SMTP server port 587 to port 25.
This is very useful when your ISP may have the SMTP port 25 blocked so you need an additional SMTP port to connect to send emails.
iptables -t nat -I PREROUTING -p tcp –dport 587 -j REDIRECT –to-port 25
Then Run iptables save
/etc/init.d/iptables save
Restart Iptables
/etc/init.d/iptables restart