Issues with live reload after updating to Ionic 6

When using ‘ionic cordova run android -l’ command the app is sucessfully sent to the hardware device, but shows an error in app, “net::ERR_EMPTY_RESPONSE (http://localhost:8100/)”. This command was working correctly when I was using Ionic 5.

I am able to build the apk successfully. Also I am able to run ‘ionic cordova run android --live-reload’ but the app does not reload when making changes with the SDK.

I am using
ionic/core 6.7.4
cordova-android 11.0.0
Node.js 20.0.0