ADB is not fully backup my device I am backing up my device. When I restore it in another device, I see that some settings is not restored. For instance, Google accounts, security settings etc. How can I fix that?

UPDATE:

I used

./adb backup -apk -shared -all -f backup_test.ab


for backup.
Because ADB doesn't backup anything other than apps. Google accounts  are stored with the rest of the web accounts in the device. It is a database file insider your user directory, ultimately, not part of any app. 

As for security settings, the settings are scattered amongst android, SettingsProvider app and some files under /data/system. Those two apps do not participate in backup and restore infrastructure of the device, so that explains why they weren't restored. 

If you want to check, try taking backup of those packages individually. You would fail everytime, irrespective of device
.